Sail E0 Webinar
Question
What is the output of this C code?
int main()
{
int var = 010;
printf("%d", var);
}
Options:
A .  2
B .  8
C .  9
D .  10
Answer: Option B


010 is octal representation of 8.



Was this answer helpful ?
Next Question

Submit Solution

Your email address will not be published. Required fields are marked *

Latest Videos

Latest Test Papers