C Programming - C Preprocessor - Discussion
Discussion Forum : C Preprocessor - Yes / No Questions (Q.No. 3)
3.
Will the program compile successfully?
#include<stdio.h>
int main()
{
printf("India" "BIX\n");
return 0;
}
Answer: Option
Explanation:
Yes, It prints "IndiaBIX"
Discussion:
5 comments Page 1 of 1.
Aarti said:
1 decade ago
Printf statement will print what you type in double quotations. It will print in one line without any space, untill you give them '\t' or'\n'.
Indra said:
1 decade ago
#include<stdio.h>
int main()
{
printf("IndiaBIX\n");
return 0;
}
Then what is the difference between both?
int main()
{
printf("IndiaBIX\n");
return 0;
}
Then what is the difference between both?
Preeti said:
1 decade ago
But is it alright to not give any control string in the printf statement?
Kishore said:
7 years ago
It does not print "IndiaBIX" it only prints "India".
Sanjay said:
8 years ago
Yes, agree @Indra.
Post your comments here:
Quick links
Quantitative Aptitude
Verbal (English)
Reasoning
Programming
Interview
Placement Papers