Write the Programs in C Language

Posted on July 24, 2023 by Soumendra Saha
Interview Preparation
DOS

For all engineering students, you can practice the below programs and prepare for your practical exam.

Unit 1

  1. Write a C Program to input 2 integer numbers and perform the following arithmetic operations- Addition, Substraction, Division and Multiplication.
  2. Write a C program to input your and print if you are elegible for Madhyamik exam. [Hint: if age >16 then elegible else not elegible]
  3. Write a C Program to check if a number is odd or even.
  4. Write a C Program to calculate sum of all elements in an array.
  5. Write a C Program to print Fibonacci series upto 10 terms.
  6. Write a C Program to check if a number is prime or not.
  7. Write a C Program to print first 20 prime numbers.
  8. Write a C Program input a string and print the number of characters in the string
  9. Write a C Program to check if a number is palindrome or not. [Example: 101, 404, 1001]

Unit 2

  1. Write a C Program input a string and print the string in upper case.
  2. Write a C program to input a string and check if the string is palindrome or not [Example: madam]
  3. Write a C Program to reverse a string using loop.
  4. Write a C Program to input street address, city, state and pin code. Then print the complete address in one string
  5. Write a C Program to input a string and print the number of vowels in the string.

Unit 3

  1. Write a C Program to printthe below pattern using loop:
    *
    * *
    * * *
    * * * *
  2. Write a C Program to printthe below pattern using loop:
    1
    2 3
    4 5 6
    7 8 9 10
  3. Write a C Program to printthe below pattern using loop:
    1
    1 0
    1 0 1
    1 0 1 0
  4. Write a C Program to printthe below pattern using loop:
          *
        * * 
      * * * 
    * * * *
  5. Write a C Program to printthe below pattern using loop:
          1
        1 0 1
      1 0 1 0 1
    1 0 1 0 1 0 1