Professional Documents
Culture Documents
LAB ASSIGNMENT - 1
Write a program to print your first name, middle name and surname in vertical
2.
order.
3. Write a program to create a flag filled with the symbol " * " using printf().
4. Write a program to accept two numbers from the user and print their sum.
Write a program to accept one number from the user and print its square and cube.
5.
S=Pow(n,2) q= pow(n,3)
Write a program to accept principal amount, rate of interest and no. of years from
6.
the user and print simple interest.
7. Write a program accept radius of a circle from the user and find out area of a circle.
8. Write a program to accept two numbers from the user and calculate their average.
Write a program to accept cost price and selling price of a product from the user
9.
and print profit.
Write a program to accept quantity and price of a product from the user and print
10.
its amount.
11. Write a program to find square root and power value using library functions.
Write a program to accept roll no., age, name, birth date and marks of three
12.
subjects from the user and print total and average.
Write a program to accept emp no., age, name, birth date, joining date, basic salary,
13.
hra, ta and pf from the user and print net salary.
14. Write a program to accept currency in Rs. and convert it into dollar.
Write a program to accept Fahrenheit degree from the user and convert it into
15.
Celsius.
Write a program to accept Rs. from the user and print total no. of Indian currency
16.
notes in it.
17. Write a program to accept two values from the user and swap them.
Write a program to accept one character from the user and print its corresponding
18.
ASCII code.