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 |
What is spark map function?
Write a program to generate the Fibinocci Series
What is the difference between scanf and fscanf?
How macro execution is faster than function ?
how to swap two nubers by using a function with pointers?
Hello. How to write a C program to check and display president party like if i type in the console "biden" and hit enter the output shoud be : "biden is democrat" and if i type "trump" and hit enter the output shoud be: "trump is republican"
15.what is the disadvantage of using macros? 16.what is the self-referential structure? 17.can a union be self-referenced? 18.What is a pointer? 19.What is the Lvalue and Rvalue? 20.what is the difference between these initializations? 21.Char a[]=”string”; 22.Char *p=”literal”; 23.Does *p++ increment p, or what it points to?
C program to find all possible outcomes of a dice?
Take an MxN matrice from user and then sum upper diagonal in a variable and lower diagonal in a separate variables. Print the result
What is the difference between functions abs() and fabs()?
Write a program that an operator and two operands read from input operand operator on the implementation and results display.
What is clrscr in c?