You are on page 1of 5

Your Name Instructor Name Allotted Time Date of Presence

Full Marks Marks Obtained

Attention: Read your problems first. There are 30 Problems are given here, out of which you have to do Seven Problems according to your selection. Every problem carries 10 Marks. Incorrect Syntax and Logic will lead to marks deduction. Comment in your program will add advantage to score.

1. Write a C program to display the average of given numbers by user. Define


your function for calling to pass the arguments.

2. Write a C program to insert and display the students Number of any Five
Subjects into a 1D array and display the values and its sum, maximum and minimum number as output in terminal.

3. Suppose I have entered value 20 & it will be stored in a variable. Now write a
C Program to display the value in terminal using pointer to a pointer.

4. Suppose you are making a catalogue of your college library where all the

books information are been stored. Now write a C Program using structure for Above example.
Program Hint: You structure may contain books name, ISBN, price, publishers name etc .

5. Write a C program to show the result of Fibonacci Series up to 7 terms on


display screen.

6. Write a C program with do-while loop, increment & decrement operators all
together.
Program Hint: You program structure should contain increment & decrement operator within a do-while statement.

Page 1 of 4

7. Write a C Program to print the Star sequence like this:

8. Write a C program to calculate the Fahrenheit scale value of given centigrade


value by user using function call by value and call by reference.

9. Write a C program to check whether a given entered number is palindrome or


not.

10. Write a C program to insert values into a two dimensional array of size 5x5.
Also display the entered values in a table format at terminal.

11. Write a C program to check whether the number entered by user is prime or not
& also check whether the number is odd or even. Design your program using nested if-else statement.

12. Write a C program to show the use of global variables & global functions in
a program. Design the program with your own logic.

13. Write a C program to show the result of 5 to the power 5 and display the result.
Program Hint: You should use mathematical function to esteem your logic .

14. Write a C program to show the result of Fibonacci series up to nth term using
recursive function.
Program Hint: You program should contain a function that should be recursive ,that means the function will call itself again and again unless the result will found and return the result to main function.

Page 2 of 4

15. Write a C program to show the use of static & const keywords using your logic.
Program Hint: Your program should contain comment line to get understand the logic of program iteration.

16. Write a C program to display the below mentioned pattern on your


display screen.

17. Write a C program to show the result of following series up to n terms upon
user input: 1 + 1/2 + 1/3 + 1/4 + ... + 1/N.
Program Hint: Your program should have for loop that can add the values in a variable and display he result at last.

18. Write a C program by passing array as function argument to show the average
of five individual salary holders of an organization.
Program Hint: Your program should have function calling statement to call the function that holds array to pass as function arguments.

19. Write a C program to display the multiplication table of size, given by user.
Program Hint: Your program should need for loop within another for loop, user should give row and column values to display the result. For further, ask your instructor.

20. Suppose you have to enter the price of five products into a one

dimensional array. Now write a C program to show the usage of pointer to an array and display the values stored in that array on the display screen.
Program Hint: Use the pointer variable, it should contain the address of array that you have stored product prices. Now use for loop and print the data/values thats entered by you.

Page 3 of 4

21. Write a C program to show the factorial of a given number, entered by user.
Program Hint: You can use recursive or iterative function to design the program.

22. Write a C program to show the sum of given sequence: 1*2+2*3+3*4........n (n+1)
of a series. The result will be shown depend upon use input for terms.
Program Hint: Your program should have for loop that can add the values in a variable and display he result at last.

23. Write a C program to show the below mentioned pattern on display screen.

24. Write a C program with the following String functions: for copying, for finding the

length of string, for comparing two strings and for concatenate two strings to get the desired result.
Program Hint: Use string header file and use an array to store your entered string and make the following functions to perform.

25. Write a simple C program with you own logic to show the use of array of pointers.
Also show the pointer increment and decrement operation in same program.

26. Write a C program to show how you can write & read data using File operation.
Program Hint: Use file pointer and file open and read function to write the data in a file and read then after. Be careful your file path should be mentioned while doing file operations.

27. Write a C program to find the HCF & LCM of any two given inputs by user.

28. Write a C program to search an element in a 1D array depends on user input &
find its location and display.

Page 4 of 4

__________________________________________________________________________ 29. Write a C program to check whether a given input number is Armstrong
number or not.

__________________________________________________________________________ 30. Write a C program to find the number of occurrence of a character in a given
string.
Program Hint: As for example suppose you entered your name, after that you entered a character to check the number of occurrences. It will display the result of occurrences in the string.

Page 5 of 4

You might also like