main()
{
intx=2,y=6,z=6;
x=y=z;
printf(%d",x)
}
Answers were Sorted based on User's Feedback
Answer / sorab
error becoz in program written as printf(%d",x)
actually it written like that printf("%d",x);
then the value 6 is print on screen
thanks ....
| Is This Answer Correct ? | 36 Yes | 7 No |
Answer / krs
"intx=2" must be "int x=2".This is First error.
secondly there is a syntax error in printf();
So there is compile time error due to this code execution.
| Is This Answer Correct ? | 14 Yes | 1 No |
Answer / dhananjay
x=6 beacuse x will contain the latest value.
| Is This Answer Correct ? | 21 Yes | 14 No |
Answer / nithya
output:
undefined symbol 'intx'
undefined symbol 'y'
undefined symbol 'z'
syntax error 'printf(%d",x)'
the above code will be change
main()
{
int x=2,y=6,z=6;
x=y=z;
printf("%d",x);
}
output:
warning error:y assign value not used
6
| Is This Answer Correct ? | 5 Yes | 0 No |
Are the outer parentheses in return statements really optional?
create a C program that displays one z,two y's,three x's until twenty six A's. plzz answer i need it tomorrow.
How can I ensure that integer arithmetic doesnt overflow?
How can I read a directory in a C program?
2 Answers Bright Outdoor, Wipro,
how can write all 1to 100 prime numbers using for loop,if and break ?
write a program which counts a product of array elements lower than 10.
# define x=1+4; main() { int x; printf("%d%d",x/2,x/4); }
Explain the term printf() and scanf() used in c language?
i want to have a program to read a string and print the frequency of each character and it should work in turbo c
write the program for prime numbers?
73 Answers Accenture, Aptech, Infosys, TCS,
for (i <= 5 && i >= -1;++i; i > 0) { printf("%d ", i); }
What would be an example of a structure analogous to structure c?