output tracing...

Write the output of the following program

1
2
3
4
5
6
7
8
9
#define ABC     20
#define XYZ    10
#define XXX    ABC - XYZ
void main()
{
        int     a;
        a = XXX * 10;
        printf("%d ", a);
}


The answer is -80.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

1 solution

Edil Tizon
Feb 6, 2015

a = xxx * 10

which is => a = ABC - XYZ * 10

     => a = 20 - 10 * 10

     => a = 20 - 100

     => a = -80

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...