main()
{
char not;
not=!2;
printf("%d",not);
}
Answer / susie
Answer :
0
Explanation:
! is a logical operator. In C the value 0 is considered to
be the boolean value FALSE, and any non-zero value is
considered to be the boolean value TRUE. Here 2 is a
non-zero value so TRUE. !TRUE is FALSE (0) so it prints 0.
| Is This Answer Correct ? | 17 Yes | 0 No |
Is the following code legal? struct a { int x; struct a b; }
What are segment and offset addresses?
main() { int i=1; while (i<=5) { printf("%d",i); if (i>2) goto here; i++; } } fun() { here: printf("PP"); }
program to Reverse a linked list
12 Answers Aricent, Microsoft, Ness Technologies,
main() { int i=400,j=300; printf("%d..%d"); }
write a program to Insert in a sorted list
¦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...
main() { char not; not=!2; printf("%d",not); }
How will you print % character? a. printf(“\%”) b. printf(“\\%”) c. printf(“%%”) d. printf(“\%%”)
#include<stdio.h> main() { struct xx { int x=3; char name[]="hello"; }; struct xx *s; printf("%d",s->x); printf("%s",s->name); }
Which version do you prefer of the following two, 1) printf(“%s”,str); // or the more curt one 2) printf(str);
main() { int i = 100; clrscr(); printf("%d", sizeof(sizeof(i))); } a. 2 b. 100 c. 4 d. none of the above