Important Questions for CIE2
Important Questions for CIE2
Important Questions for CIE2
Short Questions
1. Write a user defined function to multiply two numbers.
2. Write a program to demonstrate Recursion
3. Write a user defined function to add two numbers.
4. Write a program to calculate factorial of a number using recursion.
5. What is #include, #define directives.
6. What are the Different ways of representing Structures and
Functions?
7. Define static memory allocation.
8. Define Union? Give its syntax?
9. Define Structure? Give syntax?
10.What are generic pointers?
11.Explain Dangling Pointers?
12.What is pointer to pointer?
13.List the File Opening Modes?
14.Write about different error handling functions on files?
15.List the File Positioning Functions and their purpose?
16.Difference between Union and Structure?
Long Questions
1. Define Functions? Explain function declaration, definition and
function call.
2. Write about Linear search and Binary search with example.
3. Explain Dynamic Memory Allocation. What are the library functions
used for it.
4. Write in detail about storage classes with examples.
5. Differentiate between call by value and call by reference with
suitable example program.
6. Explain the concept of functions returning pointers with example.
7. Explain Bubble sort with example program.
8. Elaborate about pointer arithmetic.
9. Write in detail about Preprocessor directives.
10.Discuss command line arguments in detail with examples.
11.Write a short notes on
12. i.fgets() ii. fputs()
13. Explain any 2 categories of functions?
Quiz Paper
1.What is the default return type of a function in C if not specified?
a) float b) char c) int d) void
2.What does the following code output?
int a = 10, *p;
p = &a;
printf("%d", *p);
Address of a b) 10 c) 0 d) Error
3.Which of the following is the correct way to access a member of a structure using
a pointer?
a) ptr.member b) ptr->member c) *ptr.member d) ptr:member
4.If ptr is a pointer to int, having value ptr=100. After ptr++, what is the value of
ptr?