main()
{
printf("\nab");
printf("\bsi");
printf("\rha");
}
Answers were Sorted based on User's Feedback
Answer / susie
Answer :
hai
Explanation:
\n - newline
\b - backspace
\r - linefeed
Is This Answer Correct ? | 92 Yes | 13 No |
Answer / jane
<new line>ab<backspace>si<carriage return>ha
First, handle the backspace. Note that even though it is "non-erase", the next character to be output would overwrite what was backspaced over:
<new line>asi<carriage return>ha
Now, a carriage return means to go back to the beginning of the line. So the "ha" overwrites the "as" in "asi:
<new line>hai
Now, the cursor is currently sitting on the i, so the next character to be output would overwrite i.
Is This Answer Correct ? | 34 Yes | 2 No |
how to delete an element in an array
Sir... please give some important coding questions asked by product companies..
const int perplexed = 2; #define perplexed 3 main() { #ifdef perplexed #undef perplexed #define perplexed 4 #endif printf("%d",perplexed); } a. 0 b. 2 c. 4 d. none of the above
#include <stdio.h> main() { char * str = "hello"; char * ptr = str; char least = 127; while (*ptr++) least = (*ptr<least ) ?*ptr :least; printf("%d",least); }
Write a procedure to implement highlight as a blinking operation
Program to Delete an element from a doubly linked list.
4 Answers College School Exams Tests, Infosys,
#include<stdio.h> int main() { int a=3,post,pre; post= a++ * a++ * a++; a=3; pre= ++a * ++a * ++a; printf("post=%d pre=%d",post,pre); return 0; }
pls anyone can help me to write a code to print the values in words for any value.Example:1034 to print as "one thousand and thirty four only"
void main() { void *v; int integer=2; int *i=&integer; v=i; printf("%d",(int*)*v); }
¦void main() ¦{ ¦int i=10,j; ¦ j=i+++i+++i; ¦printf("%d",j); ¦getch(); ¦} ¦ output:-30 but in same question if we write as- ¦void main() ¦{ ¦int i=10; ¦ int j=i+++i+++i; ¦printf("%d",j); ¦getch(); ¦} ¦ output:-33 why output is changed from 30 to 33. Can any body answer...
Develop a routine to reflect an object about an arbitrarily selected plane
Write a C program to add two numbers before the main function is called.