C PROGRAMING PRACTICALS LIST - Final
C PROGRAMING PRACTICALS LIST - Final
PRACTICAL LIST
Q.1
1A. History and Evolution of C
1B. Applications of C
1C. Limitations of C
Q2.
2A. INSTALLATION OF CODE BLOCKS
2B. Introduction to programming cycle
2C. Specific functions of Compiler, Linker, Loader
2D. Differentiate between Assembly language, Machine language and High level language
2E. Write the ‘C’ program -PRINT YOUR NAME
Q.4
4.A Explain the C99 extensions: ‘C’ Standard Libraries: stdio.h, stdlib.h, assert.h, math.h, time.h,
ctype.h, setjmp.h, string.h, stdarg.h, unistd.h
4.B Write a C program to find the square root of a number (use math.h).
4.C Write a C program to find factorial of a number using tgamma() Method.
Q.5
5A. Write a program to calculate the sum of the first and the second last digit of a 5 digit number
entered from the keyboard.
5B. Write a program to calculate the sum of the digits of a 3-digit number which is entered from
keyboard.
5C. Write a program to reverse a 3-digit number which is entered from keyboard.
5D. Subtract Two Number Without Using Subtraction Operator.
5E. Write a C program to check whether the number is EVEN or ODD, without using any
arithmetic or relational operators
5F. Write a C program to check if two numbers are EQUAL or not without using arithmetic
operators or comparison operators.
5G. Write a C program to find the largest of three numbers using ternary operator
Q6. Write the algorithm, flowchart, and C program of the following [IF STATEMENT]
6A. Calculate the roots of a quadratic equation.
6B. Implement currency converter
6C. To check if a given number is an Armstrong number or not
Hint: (A number is called an Armstrong number if the sum of the cubes of the digits of the
number is equal to the number. For example, 153 = 1^3 + 5^3 + 3^3.)
Q7.
A. Write a C program that reads a positive integer n and then prints the following pattern
____*****
_____****
______***
_______**
________*
where n is the number of lines
B. *
**
***
****
……input n the number of lines
Q.8
8.A Write a program in C to store the elements in an array and print them.
8.B WAP to read 'n' number of values in array and display them in reverse order.
8.C WAP in C to copy the elements of one array into another array.
8.D WAP in C to merge two arrays of same size sorted in descending order.
8.E WAP in C to seperate odd and even integers into seperate arrays.
Q.9
9.A What are Macros? Discuss with a working example. Also state the types of Macros.
9.B. Differentiate between local and global variables. Explain the scope of local and global
variables with the help of an example.
9.C Discuss various storage classes in C.
Q.10
10.A Define function definition, declaration, function call and function stack.
10.B WAP in C to swap two numbers using functions – call by value and call by reference
10.C Write a program to find all prime numbers from 1-100
10.D WAP to factorial of a number using functions.
10.E WAP to generate Fibonacci series
Q. 11
11.A How do we compare two strings? Explain with the help of an example.
11.B WAP in C to reverse a string.
11.C WAP to check palindrome.
11.D What is lexicographical ordering? Is it connected with comparing two strings? Justify
Q.12
12.A What is pointer to a pointer. Explain its usage with the help of an example.
12.B What is void*. How it is used and managed in C. Explain with example.
12.C What is a function pointer? Explain in detail with a help of an example.
Q. 13
13.A Discuss in detail Structures in C, enumeration and union with the help of examples
13.B What are command line arguments.
Q.15 Write a program to perform linear search, binary search and bubble sort.
Q.16 Explain in detail file handling in C – file modes, basic file operations : read, write and
append, scope and life of variables.