?
What will be the output of the following C code?
What will be the output of the following C code?
#include <stdio.h>
int main()
{
printf("examveda\r\nclass\n");
return 0;
}
#include <stdio.h>
int main()
{
printf("examveda\r\nclass\n");
return 0;
}
Join the Discussion
Login to post a comment or share your explanation.
Login"examveda" followed by a carriage return (
), which moves the cursor to the beginning of the line, and then "class" will overwrite "exam" since it moves the cursor back to the beginning of the line.
"class" will be printed on the next line after "veda", resulting in the final output:
class
veda
veda in new line since there is an
after class