


Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!



Model Question Paper PROGRAMMING IN C AND DATA STRUCTURES (14PCD13/14PCD23) Time: 3 hrs. Max. Marks: 100
Note: Answer any FIVE full questions, choosing one full question from each module.
b. What is an operator? Explain the arithmetic, relational, logical, and assignment operators in C language.
(10 Marks)
c. Write a program in C to print the numbers from 4 to 9 and their squares. (4 Marks)
OR
b. Write the guidelines to use printf() function in C language. (8 Marks)
c. Write a program in C to find the area and perimeter of a circle. (4 Marks)
(8 Marks)
b. Explain the switch statement with syntax and example. (8 Marks) c. Design and develop a C program to read a year as an input and find whether it is leap year or not. Also consider end of the centuries.
(4 Marks)
b. Explain the use of break and continue statement in loops with example. (6 Marks) c. Design and develop a C program to r everse of an integer number NUM and check whether it is PALINDROME or NOT.
(6 Marks)
(6 Marks)
b. Explain void and parameter less functions in C with examples. (6 Marks) c. Write a C program that: i. Implements string copy operation STRCOPY (str1,str2) that copies a string str1 to another string str2 without using library function. ii. Reads a sentence and prints frequency of each of the vowels and total count of consonants.
(8 Marks)
b. What is function parameter? Explain different types of parameters in C functions.
(4 Marks)
c. Write a C function isprime (num) that accepts an integer argument and returns 1 if the argument is prime, a 0 otherwise. Write a C program that invokes this function to generate prime numbers between the given ranges.
(6 Marks)
(4 Marks)
b. What is a file? Explain how the file open and file close functions (6 Marks)