Download as pdf or txt
Download as pdf or txt
You are on page 1of 3

Dr.

Virendra Swarup Institute of Computer Studies


MCA 2k21 Assignment ‘C Programming LAB’
1) Write down the data type used in c along with range, size (in bytes), and

format specifies.

2) WAP to show working of postfix and prefix increment/decrement operators

3) WAP to convert temperature in Celsius when input is in Fahrenheit.

4) WAP to calculate sum of n natural numbers.

5) WAP to interchange the values of 2 variables without using any third

variable.

6) WAP to find greatest of three numbers.

7) WAP to find the roots of quadratic equation.

8) WAP to calculate simple interest & compound interest.

9) WAP to check whether a number is divisible by 5 and 7 or not.

10) WAP to check whether a character is vowel or consonant

11) WAP to check whether a character is alphabet or digit or special character

12) WAP to input all sides of a triangle and check whether triangle is valid or

not.

13) WAP to check whether the triangle is equilateral, isosceles or scalene

triangle.

14) WAP to demonstrate working of traffic lights.


15) If a five-digit no. is given -

a. WAP to calculate the sum of its digits.

b. WAP to reverse the number.

c. WAP to calculate sum of its first & last digit.

d. WAP to print a new number by adding one to each of its digits.

16) WAP to Make a Simple Calculator Using switch...case

17) WAP to calculate factorial of a number

18) WAP to Check Whether a Number is Palindrome or Not

19) WAP to Display Prime Numbers Between Two Intervals

20) WAP to Display Armstrong Number Between Two Intervals

21) WAP to Convert Binary Number to Decimal and vice-versa

22) WAP to Make a Simple Calculator Using switch...case

23) WAP to calculate factorial of a number

24) WAP to Check Whether a Number is Palindrome or Not

25) WAP to Display Prime Numbers Between Two Intervals

26) WAP to Check Prime or Armstrong Number Using User-defined Function

27) WAP to Convert Binary Number to Decimal and vice-versa

28) WAP to Find Transpose of a Matrix

29) WAP to Multiply to Matrix Using Multi-Dimensional Arrays

30) WAP to Find Largest Element of an Array

31) WAP to Calculate Average Using Arrays


32) WAP to Generate Fibonacci series

33) WAP to calculate factorial using recursion

34) WAP to sort element of an array

35) WAP to Store Information of a Student Using Structure

36) WAP to Store Information of a Student Using Union

37) Calculate sum of following series

1. 1^2+2^2+3^2+4^2+……. N^2
2. 1/1! + 2/2! + 3/3! + 4/4! + ... N/N!
3. 1+ 1/2 + 1/3 + 1/4 + 1/5 + ……. 1/N

38) WAP to concatenate two strings


39) WAP to reverse a string.
40) WAP to demonstrate Passing pointers to functions
41) WAP to demonstrate working of file operations (READ & WRITE) in a file
42) WAP to draw a line using computer graphics tools.

You might also like