main()
{
int i =10, j = 20;
clrscr();
printf("%d, %d, ", j-- , --i);
printf("%d, %d ", j++ , ++i);
}
a. 20, 10, 20, 10
b. 20, 9, 20, 10
c. 20, 9, 19, 10
d. 19, 9, 20, 10
Answers were Sorted based on User's Feedback
Answer / ramya
for right increment the value not change.
for the left increment the value change.
so j++=20,--i=9,j++=20,++i=10.
| Is This Answer Correct ? | 0 Yes | 1 No |
Declare an array of N pointers to functions returning pointers to functions returning pointers to characters?
void main() { int i=5; printf("%d",i++ + ++i); }
main() { int i; i = abc(); printf("%d",i); } abc() { _AX = 1000; }
Write a single line c expression to delete a,b,c from aabbcc
Write a routine to implement the polymarker function
What are segment and offset addresses?
program to Reverse a linked list
12 Answers Aricent, Microsoft, Ness Technologies,
1) int i=5; j=i++ + i++ + i++; printf("%d",j);This code gives the answer 15.But if we replace the value of the j then anser is different?why? 2)int i=5; printf("%d",i++ + i++ + i++); this givs 18.
# include <stdio.h> int one_d[]={1,2,3}; main() { int *ptr; ptr=one_d; ptr+=3; printf("%d",*ptr); }
How do you sort a Linked List (singly connected) in O(n) please mail to pawan.10k@gmail.com if u can find an anser...i m desperate to knw...
6 Answers Microsoft, MSD, Oracle,
char *someFun() { char *temp = “string constant"; return temp; } int main() { puts(someFun()); }
main() { int a=2,*f1,*f2; f1=f2=&a; *f2+=*f2+=a+=2.5; printf("\n%d %d %d",a,*f1,*f2); }