f()
{
int a=2;
f1(a++);
}
f1(int c)
{
printf("%d", c);
}
c=?
Answers were Sorted based on User's Feedback
Answer / jack
in line 4, a's value is pushed on to stack and then
increaments.........In line 6 the function f1 pops the a's
value and assigned to c so .......c is value is 2.......
| Is This Answer Correct ? | 7 Yes | 2 No |
Answer / viji
a++ is postfix operator so it first assigns its values and
then incremented. In above statement the value of a is first
assigned to c and then increment. so the output of c is 2;
| Is This Answer Correct ? | 1 Yes | 0 No |
Answer / banavathvishnu
a value will be first assigned to C in the Function and
latter it will be incremented in f() function.
so the value C remains 2
| Is This Answer Correct ? | 0 Yes | 0 No |
code snippet for creating a pyramids triangle ex 1 2 2 3 3 3
What are pointers?
0 Answers Accenture, Tavant Technologies, Zensar,
What is a keyword?
What is bubble sort in c?
FORMATTED INPUT/OUTPUT functions are a) scanf() and printf() b) gets() and puts() c) getchar() and putchar() d) all the above
what will be printed by this printf? printf("%c",printf("hi")["sharkselva"])); }
write the function int countchtr(char string[],int ch);which returns the number of timesthe character ch appears in the string. for example the call countchtr("she lives in Newyork",'e') would return 3.
How can I implement opaque (abstract) data types in C? What's the difference between these two declarations? struct x1 { ... }; typedef struct { ... } x2;
What are the uses of null pointers?
Explain a file operation in C with an example.
How can I manipulate strings of multibyte characters?
What is an auto keyword in c?