0% found this document useful (0 votes)
7 views

Problem Set 11 - Pointers, Structures Files

The document outlines a series of programming problems focused on pointers, recursion, and file handling. Each problem includes a brief description, sample input, and expected output, with varying levels of difficulty indicated. The tasks range from basic operations like addition and finding maximum values to more complex tasks such as file manipulation and recursion-based calculations.
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)
7 views

Problem Set 11 - Pointers, Structures Files

The document outlines a series of programming problems focused on pointers, recursion, and file handling. Each problem includes a brief description, sample input, and expected output, with varying levels of difficulty indicated. The tasks range from basic operations like addition and finding maximum values to more complex tasks such as file manipulation and recursion-based calculations.
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
You are on page 1/ 4

Pointers-Recursion-File related problems

SL Problem statement Difficult


y levels

1. WAP that will add two numbers using pointers. *

Sample input Sample output


35 8
59 14

2. WAP that will find the maximum number between two numbers using a pointer. *

Sample input (m,n) Sample output

3. WAP that will print the elements of an array without using index. *

Sample input Sample output

4. WAP that will calculate the length of the string using pointers. *

Sample input Sample output

5. WAP that will swap values of two variables using pointers. *

Sample input Sample output

6. WAP that will count the number of vowels and consonants in a string using pointer. *
Sample input Sample output

7. WAP that will compute the sum of all elements in an array using pointers. ***

Sample input Sample output

8. WAP that will print the elements of an array in reverse indexed order. *

Sample input Sample output

9. WAP that will display numbers 1 to 10 using recursion. **

Sample input Sample output

10. WAP that will calculate the sum of numbers from 1 to n using recursion. **

Sample input Sample output

11. WAP that will display Fibonacci Series using recursion. **

Sample input Sample output


12. WAP that will print the array elements using recursion. **

Sample input Sample output

13. WAP that will count the digits of a given number using recursion. **

Sample input Sample output

14. WAP that will get the largest element of an array using recursion. ***

Sample input Sample output

15 WAP that will print even or odd numbers in given range using recursion.

Sample input Sample output

16 WAP that will check whether a given String is Palindrome or not.

Sample input Sample output

17 WAP that will create and store the following information in the sample.txt text file.

1 Zahid
2 Tanvir
3 Akif

18 WAP that will read the sample.txt file created above.

Sample input Sample output


19 WAP that will read and display content of the sample.txt file created above.

Sample input Sample output

20 WAP that will count the number lines in a file.

Sample input Sample output

21 WAP that will append multiple lines at the end of a text file.

Sample input Sample output

You might also like