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

Assignment-1

Subject: C Programming/FE Subject Code: FEC205


Subject In charge: Mrs. Sweta Padman Div E&F

1. Write a program with algorithm and flowchart to calculate and display the sum of first n
natural number using for loop
2. Write a program with algorithm and flowchart to find whether the given number is prime or
not?
3. What are the basic data types available in C? Write the significance of each data type
4. Write a Program with algorithm and flowchart to check weather an integer entered by user is
odd or even using if-else
5. Write a program with algorithm and flowchart to generate first ‘n’ Fibonacci numbers.
6. What are the various types of operators?
7. Explain the Goto, Continue and Break statement with the help of suitable examples.
8. WAP to find the largest number among the given three numbers.
9. Define Algorithms. Write an algorithm to find the area and perimeter of a circle
10. What is the purpose of the scanf() and printf() statement ?
11. Write a C program that reads from the user an arithmetic operator and two operands, perform
the corresponding arithmetic operation on the operands using switch statement
12. Write a C program to find GCD of two numbers using ternary operator and for loop
13. Write a C program that computes the size of int, float, double and char variables
14. Write a C program that takes three coefficients (a,b,and c) of a quadratic equation (ax2 +bx+c)
as input and compute all possible roots and print them with appropriate messages.
15. Write a C-Program for a pascal triangle.
16. What is a function? Why we use functions in C language? Give an example.

You might also like