int a=1,b=2,c=3;
printf("%d,%d",a,b,c);
What is the output?
Answer Posted / jaya prakash
1,2
because arguments of functions stored in stock
in stock stored as
"%d,%d"
a
b
c
in printf fn,
args popped out from stack
first "%d,%d" is popped
it find two int involved by %d in the control string
so two more args popped out
a,b
after popping the addr's then the values in that location
printed.(1,2)
| Is This Answer Correct ? | 28 Yes | 3 No |
Post New Answer View All Answers
What are local variables c?
Hai what is the different types of versions and their differences
Write a program to compute the similarity between two strings - The program should get the two strings as input - Then it will output one single number which is the percentage of similarity between the two strings
a=10;b= 5;c=3;d=3; if(a printf(%d %d %d %d a,b,c,d) else printf("%d %d %d %d a,b,c,d);
What is string function in c?
What is declaration and definition in c?
What is the difference between text and binary modes?
Explain which of the following operators is incorrect and why? ( >=, <=, <>, ==)
What are the various types of control structures in programming?
Can a pointer be static?
Write a program with dynamically allocation of variable.
Explain modulus operator. What are the restrictions of a modulus operator?
Dont ansi function prototypes render lint obsolete?
What is the difference between scanf and fscanf?
What are the advantages of using Unions?