MCQOPTIONS
Bookmark
Saved Bookmarks
→
C Programming
→
Floating Point Issues in C Programming
→
The syntax to print a % using printf statement can..
1.
The syntax to print a % using printf statement can be done by ________.
A.
%
B.
%%
C.
%
D.
%
E.
None of these
Answer» C. %
Show Answer
Discussion
No Comment Found
Post Comment
Related MCQs
What will be the output of the following C code if following commands are used to run(considering Newfile exists)?<br><pre class="prettyprint lang-c">gcc -otest test.c<br> ./test < Newfile<br> <br> #include <stdio.h><br> int main()<br> {<br> char ch = 'U';<br> putchar(ch);<br> }<br></pre>
What will be the output of the following C code if following commands are used to run(considering Newfile exists)?<br><pre class="prettyprint lang-c">gcc -otest test.c<br> ./test > Newfile<br> <br> #include <stdio.h><br> int main(int argc, char **argv)<br> {<br> char ch = 'U';<br> putchar(ch);<br> printf(" %d n", argc);<br> }<br></pre>
What will be the output of the following C code?<br><pre class="prettyprint lang-c">#include <stdio.h><br> int main()<br> {<br> short int n;<br> scanf("%hd", &n);<br> printf("%hd", n);<br> return 0;<br> }<br></pre>
What will be the output of the following C code?<br><pre class="prettyprint lang-c">#include <stdio.h><br> int main()<br> {<br> char ch1[] = "HelloInterviewMania!";<br> char ch2[13];<br> scanf(ch1, "%s", ch2);<br> printf("%s n", ch2);<br> return 0;<br> }<br></pre>
What will be the output of the following C code?<br><pre class="prettyprint lang-c">#include <stdio.h><br> int main()<br> {<br> char *num;<br> scanf("%s", num);<br> return 0;<br> }<br></pre>
What will be the output of the following C code?<br><pre class="prettyprint lang-c">#include <stdio.h><br> int main()<br> {<br> int num;<br> scanf("%d", num);<br> printf("%d n", num);<br> return 0;<br> }<br></pre>
What will be the output of the following C code?<br><pre class="prettyprint lang-c">#include <stdio.h><br> int main()<br> {<br> short int num;<br> scanf("%h*d", &num);<br> printf("%hd", h);<br> return 0;<br> }<br></pre>
What will be the output of the following C code?<br><pre class="prettyprint lang-c">#include <stdio.h><br> int main()<br> {<br> short int n;<br> scanf("%*hd", &n);<br> printf("%hd", n);<br> return 0;<br> }<br></pre>
What will be the output of the following C code if 2 character is typed by the user?<br><pre class="prettyprint lang-c">#include <stdio.h><br>#include <string.h><br> int main()<br> {<br> char line[25];<br> fgets(line, 25, stdin);<br> printf("%d n", line[2]);<br> return 0;<br> }<br></pre>
What will be the output of the following C code?<br><pre class="prettyprint lang-c">#include <stdio.h><br>#include <string.h><br> int main()<br> {<br> char line[25];<br> FILE *fp;<br> fp = fopen("file.txt", "r");<br> while (fgets(line, 25, fp))<br> fputs(line, stdout);<br> return 0;<br> }<br></pre>
Reply to Comment
×
Name
*
Email
*
Comment
*
Submit Reply