June 2022
June 2022
3.a) What is an array? Describe declaration and initialization of one and two dimensional
d
arrays with examples.
b) Discuss basic string functions available in C with examples. [7+8]
Pa
4.a) What is a structure? Explain defining and initializing a structure with example.
b) What is a pointer? Write a C program to find sum of all elements in an array using a
pointer. [7+8]
pe
5.a) Differentiate between text and binary files?
b) A file named DATA contains a series of integer numbers. Write a C program to read
these numbers and then write all ‘even’ numbers to a file called EVEN and all ‘odd’
rs
numbers to a file called ODD and then finally print the contents of these two files.
[5+10]
Ju
6.a) Explain various dynamic memory allocation functions with examples.
b) Discuss call by value and call by reference with example programs. [7+8]
7.a) Explain commonly used preprocessor commands like include and define with example
ne
programs.
b) Write a C program to find factorial of a given number using recursion. [7+8]
--ooOoo--