Question & Answer: An expression that is either true or false is a(n) a condition b variable c relational d none Which one of these is not the name of a C library function? a…..

pir relational none An expression that is either true or false is a(n) a condition variable oWhich one of these is not the name of a Clibrary function? void d scanf aprintr b sqrt 1 mark each Answer all questions What is a compiler? It canvorts our Computer language、 2 What would be displayed by the following program? int main( void) double a, b a = 37.56; b=101.117; printf(Is it %. If%.4An, a, b); return (0); 3 What data types would you use to tthe following items: (i) (ii) (ii) number ofchildren at school → Charac te a letter grade on an exam the average number of school days a child is absent each year douhle Rewrite the following mathematical expressions in using math library functions: (Gi) b-4ac () u -v (o) sert 5 What is illegal about the following program fragment? #include <stdio.h> #define Pl 3.14 int main(void) double circum, r scanf(%lf%1f, circum, r); PI = circum / (2 * r); Page 2 of 5

An expression that is either true or false is a(n) a condition b variable c relational d none Which one of these is not the name of a C library function? a printf b squareroot c void d scanf Answer all questions What is a compiler? What would be displayed by the following program? int main(void) { double a, b: a = 37.56: b = 101.117: printf(“Is it %. 1f %.4fn”, a, b): return (0): } What data types would you use to represent the following items: (i) number of children at school (ii) a letter grade on an exam (iii) the average number of school days a child is absent each year Rewrite the following mathematical expressions in ‘C’ using math library functions: (i) b^2 – 4ac (ii) Squareroot (u – v) What is illegal about the following program fragment? #include # define P1 3.14 int main(void) { double circum, r: scanf(“%1f%1f”, circum. r): PI = circum/(2* r): }

Expert Answer

 

9. a) condition is a statement that can turn out to be true or false.

10. c) void – Void is not a function it is a keyword which means empty or nothing.

1. A compiler a program that converts any high level language / medium level language to machine code so that computer understands it and run the instructions depicted by machine code.

2. The output is Is it 37.560000 101.1170 , %.4f tells the compiler to print first 4 decimal places and lf prints standard double length with 6 digits after decimal

3.

i) int

ii) char

iii) double

4.

i) pow(b,2) – 4*a*c

ii) sqrt (u-v)

5.

The issue is with line

PI = circum/(2*r)

PI is a constant defined and its value cannot be changed..

Still stressed from student homework?
Get quality assistance from academic writers!