- A b
- B b.0000000
- C run time error
- D 98.000000
- Share this MCQ
Answer:
D
Click me to Read more Question & Answer of
Data Types in C Language
Share this MCQ
Output:
98.000000
Since the ASCII value of b is 98, the same is assigned to the float variable and printed.
This code is a C language program that includes the standard input/output library and defines the main
function.
Within the main
function, there is a declaration of a float variable x
which is assigned the ASCII value of character 'b'.
The printf
statement is then used to print the value of the x
variable as a floating-point number using the %f
format specifier.
Since the ASCII value of 'b' is 98, the output of the program will be 98.000000
.
Finally, the main
function returns an integer value of 0 to signify that the program has executed successfully.
Share this MCQ