The document provides instructions for 10 decision control programs to write in C. The programs include finding the maximum of three numbers, absolute value of a number, whether an integer is odd or even, if a year is a leap year, maximum of 3 numbers, absolute value, if a character is a vowel, if a number is positive/negative/zero, and determining the type of character input. The final program is to find the roots of a quadratic equation using the quadratic formula.
The document provides instructions for 10 decision control programs to write in C. The programs include finding the maximum of three numbers, absolute value of a number, whether an integer is odd or even, if a year is a leap year, maximum of 3 numbers, absolute value, if a character is a vowel, if a number is positive/negative/zero, and determining the type of character input. The final program is to find the roots of a quadratic equation using the quadratic formula.
The document provides instructions for 10 decision control programs to write in C. The programs include finding the maximum of three numbers, absolute value of a number, whether an integer is odd or even, if a year is a leap year, maximum of 3 numbers, absolute value, if a character is a vowel, if a number is positive/negative/zero, and determining the type of character input. The final program is to find the roots of a quadratic equation using the quadratic formula.
Write a C Program 1. Write a C program to find the maximum of three numbers using conditional operator. 2. Write a C program to find the absolute value of a number using conditional operator. (e.g. if input is +25, then output is 25; if input is 25, then output is 25; if input is −25, then output is 25). 3. To find out whether any integer, input through the keyboard, is odd or even 4. To determine whether a given year, input through the keyboard, is leap year or not. 5. To find the maximum of 3 numbers. 6. To find the absolute value of a number. 7. To check whether a given alphabet is vowel or not. 8. To check whether a number input from keyboard is positive or negative or zero. 9. To determine whether a character input from keyboard is a capital letter, a small case letter, a digit or a special symbol. 10. Write a C Program to find the roots of a quadratic equation ax2 + bx + c = 0 for all possible combination of a, b and c. [A quadratic equation will have two roots which are obtained using the following expression: x = −b ± (sqrt of (b2 −4ac))/2a Note: when b2 −4ac > 0 the roots are real and unequal b2 −4ac = 0 the roots are real and equal i.e. x = −b/2a b2 −4ac < 0 the roots are imaginary]