Question
QUESTION 17 What will be the output of following statements? char a[] = 0; printf(%s, a)? printf(The string is empty ):printf(The string is not empty
QUESTION 17
-
What will be the output of following statements?
char a[] = "\0";
printf("%s", a)? printf("The string is empty "):printf("The string is not empty ");
A. The string is empty
B. The string is not empty
C. Compile-time Error
D. Run-time Error
2 points
QUESTION 18
-
What will be the output of following statements?
char str1[] = "Hello";
char str2[] = "Hello";
(str1 == str2)? printf("Equal "): printf("Unequal ");
A. Unequal
B. Equal
C. Compile-time Error
D. Run-time Error
2 points
QUESTION 19
-
What will be the output of following statements?
char str[] = "Hello";
char *s = str;
printf("%s ", s++ +3);
printf("%s",s);
A. o o
B. lo lo
C. lo ello
D. llo llo
2 points
QUESTION 20
-
What will be the output of following statement?
printf(7+"Spring Break! ");
A. Spring Break!
B. Spring
C. B
D. Break!
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started