0% found this document useful (0 votes)
36 views10 pages

Lab Assignment 3: Name - Sachin Kumar Gupta Roll No. - 21075074 ID

Uploaded by

Subhasree Ghosh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
36 views10 pages

Lab Assignment 3: Name - Sachin Kumar Gupta Roll No. - 21075074 ID

Uploaded by

Subhasree Ghosh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 10

Lab Assignment 3

CSO101

Name - SACHIN KUMAR GUPTA

Roll No. – 21075074

ID – [email protected]
Programme 1 :
Write a C program to implement a calculator which
performs +, -, \, * operations using switch case.

Output :
Programme 2:
Write a C program to get marks from the user and
assign the following grades and print it.
Mark Grade
<50 F
50-70 C
70-90 B
>90 A

Output:
Programme 3:
Write a C program to print if a number is odd or even.

Output:
Programme 4:
Write a C program to find the roots of a quadratic
equation. You should print the roots even if they are
complex.

Output:
Programme 5:
Write a C program to implement the modulus
function without using modulo operator.

Output:
Programme 6:
Write a C program to test if the numbers entered can
form sides of a triangle or not.

Output:
Programme 7:
Write a C program to print the name given numeric value of a month. For example it
should print November if 11 is entered and error if any number less than 1 or greater than
12 is entered.

Output:
Programme 8 :
Write a C program to find if a given year is leap year
or not.

Output:
Programme 9:
Write a C program to print the sine of the value
entered if choice is 1 or cosine if choice is 2. If any
other value is entered, then it should return tan of
the value.

Output:

You might also like