-
-
-
main()
{
int i;
clrscr();
printf("%d", &i)+1;
scanf("%d", i)-1;
}Main() { int i; clrscr(); printf("%d", &i)+1; scanf("%d", i)-1; }
A) Runtime error. Access violationB) Compile error. Illegal syntaxC) None of the aboveD) Runtime errorExplanation: printf( ) prints address/garbage of i, scanf() dont have & sign, so scans address for i +1, -1 dont have any effect on code.
-
How will you print % character?
A) printf(“%%”)B) printf(“\%”)C) printf(“%”)D) printf(“%%”)
-
-
-
-
-
-
-
-
-
-
-
Swapping of two numbers
How to swap two numbers without using temporary variable?
-
Even or Odd number
Write a program to find a number if even or odd with out using conditional operator and if-else?
-
Write the equivalent expression for x%8?
x&7 Write expressions to swap two integers without using a temporary variable?
-
-
-
C Interview Questions
Ans