Share
Explore BrainMass

In the following lines of code, the result that is printed is the letter "B". Why does this occur?

In the following lines of code, the result that is printed is the letter "B". Why does this occur?

int a = 65;
a = a + 1;
printf("The value is: %c",a);

Solution Preview

When you use "%c" in the format specifier of the printf statement with an integer variable as argument, it is interpreted as an ASCII (American ...

$2.19