f(x,y,z)
{
y = y+1;
z = z+x;
}
main()
{
int a,b;
a = 2
b = 2;
f(a+b,a,a);
print a;
}
what is the value of 'a' printed
Answer Posted / sachin arora
Answer a=2
because f is a function and that time STACK concept are
used ,in a function last value a is printed and a=2;
so result will b 2
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Can I initialize unions?
What is the difference between text and binary modes?
Explain the difference between the local variable and global variable in c?
Explain what is the benefit of using enum to declare a constant?
What is "Hungarian Notation"?
What are the preprocessor categories?
What does sizeof return c?
find the output? void r(int a[],int c, int n) { if(c>n) { a[c]=a[c]+c; r(a,++c,n); r(a,++c,n); } } int main() { int i,a[5]={0}; r(a,0,5); for(i=0;i<5;i++) printf("\n %d",a[i]); getch(); }
List some of the dynamic data structures in C?
Explain what are preprocessor directives?
Explain how can you tell whether a program was compiled using c versus c++?
If null and 0 are equivalent as null pointer constants, which should I use?
a) Identify the following declarations. Ex. int i (integer variable) float a[l0](array of 10 real nos) int (*f())() void *f int (*f()) [] void *f int f[] [] [] char *(*f) () int (*f[]) [] float(*f) [] [] float **f int ******f
What is 2 d array in c?
Calculate the weighted average of a list of n numbers using the formula xavg = f1x1+f2x2+ ….+ fnxn where the f’s are fractional weighting factors, i.e., 0<=fi<1, and f1+f2+….+fn = 1