Satyam P.

asked • 03/19/20

Printing Problem in C programming


For the following code:

int a = -1;
int b = a * 5;
printf("a is %d, and b is %d.\n", a, b);

What is the output?


int x = -1;
int y = 3;
x= x + Y;
printf("x - y is %d.\n", x - y);

1 Expert Answer


Patrick B. answered • 03/19/20

4.7 (31)

Math and computer tutor/teacher

Still looking for help? Get the right answer, fast.

Ask a question for free

Get a free answer to a quick problem.
Most questions answered within 4 hours.


Find an Online Tutor Now

Choose an expert and meet online. No packages or subscriptions, pay only for the time you need.