String
String
String
------------------------------------------------------------------------------------------
2) Write a one line code to copy the string into another buffer.
3) Write a program to find the no. of times the character is found in a
given string.
8) Write a program to find the no. of words are presented in a given string
line.
Note: User has to input the string line at runtime.
14) Write a program to convert the characters Upper to Lower and Lower
to Upper in a given string.
16) Write a program to accept two strings from user into two character
array and copy one by one character into another destination array.
Ex: First String: “abcdefg”
Second String: “1234”
Then Destination String is “a1b2c3d4efg”
17) Write a program to find the no. of times substring is found in a given
string.
19) Write a program to replace the words in reverse order in a given string
line.
Ex: Input: “world changed your thoughts”
Output: “thoughts your changed world”
20) Write a program to read two strings through the keyboard like the
following example and replace any word of the second string with the first
string.
Ex: Input:- Fist String: “Tomorrow”
Second String: “Today is Sunday”
Replace word: “Today”.
Ex: "Osama bin laden" , "Old man in a base" both are anagrams.
“study” , “dus%@ty123” both are anagrams.
Here after removing special characters and digits ---->
“ dusty “.
22) Write a program for Decryption of a given Encrypted string line with
respect to given key number.
The letter at position of the key and a multiple of key is interchanged with
the next letter. Spaces and special characters are to be ignored. If the letter
is the last one in the array, then no interchange is required.
Design a function called Decryptor to receive the Encrypted data from the
main function and decrypt the data.
4 8 12 16 20 24 28 32 36
Ex: Input String : “Expcet Porblmes adn eat thef mor rbeafkast”.
If Key : 4 then, 4 multiples ---> 4,8,12,16,20,24,28,32,36 these
letters has to interchange with next
Characters.
Output String : “Expect Problems and eat them for breakfast”.
Input String : “Our rgeaetst ewakenss iles ni giivng pu. thm eosc teratin
awy ts ouceed si
alwyas tt ory ujst noe mroe tmie”.
Key : 4
Output : ????????
A. Tandava Ramakrishna.
Email: ramakrishna@vectorindia.org