main()
{
int i=-1;
+i;
printf("i = %d, +i = %d \n",i,+i);
}
Answer / susie
Answer :
i = -1, +i = -1
Explanation:
Unary + is the only dummy operator in C. Where-ever it
comes you can just ignore it just because it has no effect
in the expressions (hence the name dummy operator).
Is This Answer Correct ? | 20 Yes | 1 No |
char *someFun() { char *temp = “string constant"; return temp; } int main() { puts(someFun()); }
#define int char main() { int i=65; printf("sizeof(i)=%d",sizeof(i)); }
write a simple calculator c program to perform addition, subtraction, mul and div.
0 Answers United Healthcare, Virtusa,
What is your nationality?
main() { float i=1.5; switch(i) { case 1: printf("1"); case 2: printf("2"); default : printf("0"); } }
main() { int i=_l_abc(10); printf("%d\n",--i); } int _l_abc(int i) { return(i++); }
how can i cast a char type array to an int type array
what will be the position of the file marker? a: fseek(ptr,0,SEEK_SET); b: fseek(ptr,0,SEEK_CUR);
main() { int i, j, *p; i = 25; j = 100; p = &i; // Address of i is assigned to pointer p printf("%f", i/(*p) ); // i is divided by pointer p } a. Runtime error. b. 1.00000 c. Compile error d. 0.00000
#define f(g,g2) g##g2 main() { int var12=100; printf("%d",f(var,12)); }
main() { int a[10]; printf("%d",*a+1-*a+3); }
main() { int i=5; printf("%d",++i++); }