0

Hi there,

#include<stdio.h>
main()
{
int i;
i=1,2,3;
printf("Value of i with assignment as i=1,2,3 is %d\n", i);
i=(1,2),3;
printf("Value of i with assignment as i=(1,2),3 is %d\n", i);
i=1,(2,3);
printf("Value of i with assignment as i=1,(2,3)is %d\n", i);
i=(1,2,3);
printf("Value of i with assignment as i=(1,2,3) is %d\n", i);

}

Output:

Value of i with assignment as i=1,2,3 is 1
Value of i with assignment as i=(1,2),3 is 2
Value of i with assignment as i=1,(2,3)is 1
Value of i with assignment as i=(1,2,3) is 3

So, what is it all about?

Thanks
Swapna

2
Contributors
1
Reply
3
Views
6 Years
Discussion Span
Last Post by Ancient Dragon
This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.