0% found this document useful (0 votes)
14 views4 pages

String Manipulation Programming Tasks

The document outlines a series of programming challenges categorized into Easy, Medium, Advanced, and Logical Questions levels. Each level contains specific tasks such as counting vowels, checking for palindromes, and manipulating strings in various ways. The challenges are designed to test and improve coding skills across different complexities.

Uploaded by

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

String Manipulation Programming Tasks

The document outlines a series of programming challenges categorized into Easy, Medium, Advanced, and Logical Questions levels. Each level contains specific tasks such as counting vowels, checking for palindromes, and manipulating strings in various ways. The challenges are designed to test and improve coding skills across different complexities.

Uploaded by

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

Easy Level

1. Write a program to count the number of vowels and consonants in a string.

2. Check whether a string is palindrome (without using built-in functions).

3. Count the number of words in a sentence.

4. Find the frequency of each character in a string.

5. Convert a string to uppercase and lowercase without using library functions.

6. Remove all whitespaces from a string.

7. Reverse a string without using strrev().

8. Count digits, letters, spaces, and special characters.

9. Replace all occurrences of a character in a string.

10. Find the length of a string manually (without strlen).

Medium Level

11. Find the largest and smallest word in a given sentence.

12. Remove duplicate characters from a string.

13. Print the first non-repeating character in a string.

14. Check if two strings are anagrams (e.g., listen and silent).
15. Find the most frequent character in a string.

16. Count the number of repeated words in a sentence.

17. Capitalize the first letter of each word in a sentence.

18. Check if a string contains only digits.

19. Rotate a string (e.g., "abcd" → "bcda").

20. Check if one string is a rotation of another (ABCD → CDAB).

Advanced Level (Placement + Coding Rounds)

21. Print all permutations of a string.

22. Compress a string: "aaabbccd" → "a3b2c2d1".

23. Remove adjacent duplicates: "aaabbbaa" → "aba".

24. Longest substring without repeating characters.

25. Longest palindromic substring (e.g., "babad" → "bab" or "aba").

26. Count number of substrings that start and end with same character.

27. Pattern matching (without using strstr()).

28. Find common characters between two strings.


29. Convert Roman numbers to integers.

30. Given two strings, print edit distance (minimum insert/delete/replace operations).

Zoho / TCS / CTS Style Logical Questions

31. Reverse words in a string without changing their characters:

Input: "I love coding"


Output: "coding love I"

32. Sort words in a string based on length.

33. Validate strong password (must contain uppercase, lowercase, number, special char).

34. Remove duplicates but maintain original order:

Input: "banana"
Output: "ban"

35. Frequency sorted output:

Input: mississippi
Output: i4 s4 p2 m1

Coding Challenge Style

36. Convert string to zig-zag pattern and read row-wise.

37. Group anagrams from a list of strings.


38. Implement atoi() function (convert string to integer).

39. Check if a sentence is a pangram.

40. Implement substring search using KMP algorithm (for competitive coding).

You might also like