0% found this document useful (0 votes)
3 views7 pages

Important Programs

The document outlines various operations and tasks related to single-dimensional arrays, double-dimensional arrays (matrices), and string manipulation. It includes basic operations such as reading, displaying, searching, sorting, and modifying arrays and strings, as well as advanced operations like merging, splitting, and encryption. Each section provides a comprehensive list of functionalities that can be performed on arrays and strings, catering to both basic and advanced levels.

Uploaded by

National Academy
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views7 pages

Important Programs

The document outlines various operations and tasks related to single-dimensional arrays, double-dimensional arrays (matrices), and string manipulation. It includes basic operations such as reading, displaying, searching, sorting, and modifying arrays and strings, as well as advanced operations like merging, splitting, and encryption. Each section provides a comprehensive list of functionalities that can be performed on arrays and strings, catering to both basic and advanced levels.

Uploaded by

National Academy
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd

ARRAY

🔹 SINGLE DIMENSIONAL ARRAY (1D)


🔸 Basic Operations

 Read and display array elements


 Find sum of all elements
 Find average of elements
 Find maximum element
 Find minimum element

 Find second largest element
 Find second smallest element
 Count total number of elements

🔸 Even / Odd / Positive / Negative

 Find sum of even numbers


 Find sum of odd numbers
 Count even numbers
 Count odd numbers
 Find largest even element
 Find smallest odd element
 Count positive numbers
 Count negative numbers
 Separate even and odd elements into two arrays
 Separate positive and negative elements into two arrays

🔸 Searching

 Perform linear search


 Perform binary search
 Find position of an element
 Count frequency of an element
 Find pair of elements with given sum
 Check whether a number is present in the array

🔸 Sorting

 Sort array in ascending order


 Sort array in descending order
 Sort names alphabetically
 Sort marks in descending order

🔸 Reverse / Shift / Rotate

 Reverse the array


 Left shift array elements
 Right shift array elements
 Rotate array left
 Rotate array right

🔸 Frequency / Duplicates

 Find frequency of each element


 Count duplicate elements
 Remove duplicate elements
 Display unique elements

🔸 Mathematical / Logical

 Find product of array elements


 Find sum of squares of elements
 Check whether array is palindrome
 Check whether array is sorted
 Find difference between largest and smallest
 Check whether array elements form an arithmetic progression
 Replace prime numbers with zero
 Count perfect numbers in array

🔸 Merge & Split (IMPORTANT)

 Merge two arrays


 Merge two sorted arrays
 Merge arrays in ascending order
 Merge arrays in descending order
 Split array into even and odd arrays
 Split array into positive and negative arrays

🔸 Insert / Delete / Modify


 Insert an element at a given position
 Delete an element from a given position
 Replace an element at a given position
 Update array elements by a given value

🔹 DOUBLE DIMENSIONAL ARRAY (2D / MATRICES)


🔸 Input / Display

 Read and display a matrix


 Display matrix row-wise
 Display matrix column-wise

🔸 Row / Column Operations

 Find sum of each row


 Find sum of each column
 Find row with maximum sum
 Find column with minimum sum
 Find row-wise maximum elements
 Find column-wise minimum elements

🔸 Diagonal Operations

 Display principal diagonal elements


 Display secondary diagonal elements
 Find sum of principal diagonal
 Find sum of secondary diagonal
 Interchange main and secondary diagonals

🔸 Matrix Properties

 Check whether matrix is a square matrix


 Check whether matrix is an identity matrix
 Check whether matrix is a diagonal matrix
 Check whether matrix is symmetric
 Check whether matrix is upper triangular
 Check whether matrix is lower triangular
 Check whether matrix is a sparse matrix
 Count non-zero elements in a matrix
🔸 Matrix Operations

 Add two matrices


 Subtract two matrices
 Multiply two matrices
 Find transpose of a matrix

🔸 Search & Replace

 Search an element in matrix


 Find position of an element in matrix
 Replace diagonal elements with zero
 Replace non-diagonal elements with zero

🔸 Mirror / Reflection Matrix

 Check whether a matrix is a mirror matrix


 Find the vertical mirror of a matrix
 Find the horizontal mirror of a matrix
 Check whether two matrices are mirror images

🔸 Advanced ISC-Level Matrix Problems

 Interchange rows of a matrix


 Interchange columns of a matrix
 Find largest element in matrix
 Find smallest element in matrix
 Check whether matrix is palindrome row-wise
BASIC STRING OPERATIONS
🔸 Input / Output

 Read and display a string


 Read and display a sentence (including spaces)
 Display characters of a string one by one

🔸 Length & Access

 Find the length of a string


 Access a character at a given position
 Replace a character at a given position

🔸 Comparison & Searching

 Compare two strings


 Check whether two strings are equal
 Find the first occurrence of a character in a string
 Find the last occurrence of a character in a string
 Check whether a substring is present in a string
 Find the position of a substring in a string

🔸 Substring / Split / Join

 Extract a substring from a string


 Split a string into words
 Join two strings
 Concatenate two strings
 Insert a substring into a string

🔸 Case Conversion

 Convert a string to uppercase


 Convert a string to lowercase
 Convert the first character of each word to uppercase
🔸 Reverse & Palindrome

 Reverse a string
 Check whether a string is a palindrome
 Reverse words in a sentence

🔸 Count / Frequency

 Count vowels in a string


 Count consonants in a string
 Count digits in a string
 Count special characters in a string
 Count the frequency of each character in a string
 Count the number of words in a sentence

🔸 Replace / Remove

 Replace a character with another character


 Replace a substring with another substring
 Remove all spaces from a string
 Remove duplicate characters from a string
 Remove all vowels from a string

🔸 Sorting & Arrangement

 Sort characters of a string in ascending order


 Sort words of a sentence alphabetically
 Arrange words in reverse order

🔸 Validation (ISC Focus)

 Check whether a string contains only digits


 Check whether a string contains only alphabets
 Check whether a string contains only alphanumeric characters
 Validate a password based on given rules
🔹 ADVANCED STRING HANDLING (ISC
FOCUS)
🔸 Pattern & Matching

 Check whether a string contains a pattern


 Find all occurrences of a substring
 Replace all occurrences of a substring
 Count number of occurrences of a substring

🔸 Encryption / Encoding (ISC level)

 Convert string to ASCII values


 Convert ASCII values back to string
 Simple encryption using Caesar Cipher
 Decrypt a Caesar Cipher string

🔸 String Comparison & Similarity

 Check whether two strings are anagrams


 Check whether one string is a rotation of another
 Check whether one string is a permutation of another

🔸 Miscellaneous (Exam Oriented)

 Find the largest word in a sentence


 Find the smallest word in a sentence
 Remove duplicate words from a sentence
 Count words having even length
 Count words having odd length

You might also like