Lab 1
Lab 1
Lab 1
2. Write a C program to convert temperature from Fahrenheit to Celsius and vice versa.
4. Write a program to check whether a triangle is valid or not, when the three angles of the
triangle are entered through the keyboard. A triangle is valid if the sum of all the three
angles is equal to 180 degrees.
5. Given three points (x1, y1), (x2, y2) and (x3, y3), write a program to check if all the three
points fall on one straight line.
6. Given the coordinates (x, y) of a centre of a circle and its radius, write a program which
will determine whether a point lies inside the circle, on the circle or outside the circle. (Hint:
Use sqrt( ) and pow( ) functions).