main()

{

char *p = “ayqm”;

char c;

c = ++*p++;

printf(“%c”,c);

}



main() { char *p = “ayqm”; char c; c = ++*p++; prin..

Answer / susie

Answer :

b

Explanation:

There is no difference between the expression ++*(p++) and
++*p++. Parenthesis just works as a visual clue for the
reader to see which expression is first evaluated.

Is This Answer Correct ?    5 Yes 1 No

Post New Answer

More C Code Interview Questions

main() { char *p; int *q; long *r; p=q=r=0; p++; q++; r++; printf("%p...%p...%p",p,q,r); }

1 Answers  


¦void main() ¦{ ¦int i=10,j; ¦ j=i+++i+++i; ¦printf("%d",j); ¦getch(); ¦} ¦ output:-30 but in same question if we write as- ¦void main() ¦{ ¦int i=10; ¦ int j=i+++i+++i; ¦printf("%d",j); ¦getch(); ¦} ¦ output:-33 why output is changed from 30 to 33. Can any body answer...

3 Answers  


void func1(int (*a)[10]) { printf("Ok it works"); } void func2(int a[][10]) { printf("Will this work?"); } main() { int a[10][10]; func1(a); func2(a); } a. Ok it works b. Will this work? c. Ok it worksWill this work? d. None of the above

1 Answers   HCL,


main() { int i; i = abc(); printf("%d",i); } abc() { _AX = 1000; }

2 Answers  


main(int argc, char **argv) { printf("enter the character"); getchar(); sum(argv[1],argv[2]); } sum(num1,num2) int num1,num2; { return num1+num2; }

1 Answers  






Write out a function that prints out all the permutations of a string. For example, abc would give you abc, acb, bac, bca, cab, cba. You can assume that all the characters will be unique.

5 Answers   IITR, Microsoft, Nike,


main() { int i=0; while(+(+i--)!=0) i-=i++; printf("%d",i); }

9 Answers   CSC, GoDB Tech, IBM,


write a c-program to find gcd using recursive functions

5 Answers   HTC, Infotech,


How do you create a really large matrix (i.e. 3500x3500) in C without having the program crash? I can only reach up to 2500. It must have something to do with lack of memory. Please help!

1 Answers  


#define DIM( array, type) sizeof(array)/sizeof(type) main() { int arr[10]; printf(“The dimension of the array is %d”, DIM(arr, int)); }

1 Answers  


programming in c lanugaue programm will errror error with two header file one as stdio.h and other one is conio.h

1 Answers  


What is the subtle error in the following code segment? void fun(int n, int arr[]) { int *p=0; int i=0; while(i++<n) p = &arr[i]; *p = 0; }

1 Answers  


Categories