0% found this document useful (0 votes)
124 views2 pages

Strings and Pointers

The document provides a list of programming problems related to strings and pointers in C. For strings, it includes tasks like finding the length of a string, counting words, comparing strings, finding characters, substrings, and converting case. For pointers, it lists problems involving creating, initializing, and using pointers to manipulate arrays, strings, matrices, and return multiple values from functions. There are a total of 31 problems presented between the two sections on strings and pointers.

Uploaded by

Akhilesh Patil c
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)
124 views2 pages

Strings and Pointers

The document provides a list of programming problems related to strings and pointers in C. For strings, it includes tasks like finding the length of a string, counting words, comparing strings, finding characters, substrings, and converting case. For pointers, it lists problems involving creating, initializing, and using pointers to manipulate arrays, strings, matrices, and return multiple values from functions. There are a total of 31 problems presented between the two sections on strings and pointers.

Uploaded by

Akhilesh Patil c
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
You are on page 1/ 2

Strings

1. Write a program in C to find the length of a string without using the library function.
2. Write a program in C to count the total number of words in a string.
3. Write a C program to find length of a string.
4. Write a C program to copy one string to another string.
5. Write a C program to concatenate two strings.
6. Write a C program to compare two strings.
7. Write a program in C to count total number of alphabets, digits and special characters in
a string.
8. Write a program in C to find maximum occurring character in a string.
9. Write a C program to find first occurrence of a character in a given string.
10. Write a C program to remove all repeated characters from a given string.
11. Write a C program to replace first occurrence of a character with another in a string.
12. Write a program in C to extract a substring from a given string.

Test Data :

Input the string : this is test string

Input the position to start extraction :9

Input the length of substring :4

Expected Output :

The substring retrieve from the string is : " test "

13. Write a program in C to convert a string to lowercase.

Pointers

1. Write a C program to create, initialize and use pointers.


2. Write a C program to add two numbers using pointers.
3. Write a C program to swap two numbers using pointers.
4. Write a C program to input and print array elements using a pointer.
5. Write a C program to copy one array to another using pointers.
6. Write a C program to swap two arrays using pointers.
7. Write a C program to reverse an array using pointers.
8. Write a C program to search an element in array using pointers.
9. Write a C program to access a two dimensional array using pointers.
10. Write a C program to add two matrix using pointers.
11. Write a C program to multiply two matrix using pointers.
12. Write a C program to find length of string using pointers.
13. Write a C program to copy one string to another using pointers.
14. Write a C program to concatenate two strings using pointers.
15. Write a C program to compare two strings using pointers.
16. Write a C program to find reverse of a string using pointers.
17. Write a C program to sort array using pointers.
18. Write a C program to return multiple value from function using pointers.

You might also like