Discussion :: C-MCQs
-
What is the output of this C code?
int main()
{
float x = 'a';
printf("%f", x);
return 0;
}
Answer : Option D
Explanation :
Since the ASCII value of a is 97, the same is assigned to the float variable and printed.
Output:
$ cc pgm8.c
$ a.out
97.000000
Be The First To Comment