main()
{
printf(5+"Vidyarthi Computers");
}
Answers were Sorted based on User's Feedback
Answer / sujith
I would rather say
rthi Computers
Reason is printf() takes a pointer to char to print the
string. we said 5+"Vidyarthi Computers" so this is
interpreted as "rthi Computers" becuase we have added 5 to
the base pointer. so it will print only "rthi Computers".
| Is This Answer Correct ? | 18 Yes | 0 No |
Answer / vignesh1988i
rthi computers
since this will be taken as a string and 5 is the subscript value and prints the remaining characters from 'r'.
| Is This Answer Correct ? | 3 Yes | 0 No |
Answer / shruti
arthi computers..
i think 5 characters is 0 - 5 and not 1- 5...
| Is This Answer Correct ? | 2 Yes | 2 No |
Difference between Class and Struct.
13 Answers Ericsson, Motorola, Wipro,
Do you have any idea how to compare array with pointer in c?
#include main() { int *p, *c, i; i = 5; p = (int*) (malloc(sizeof(i))); printf(" %d",*p); *p = 10; printf(" %d %d",i,*p); c = (int*) calloc(2); printf(" %d ",*c); }
What are the keywords in c?
What language is windows 1.0 written?
What is void c?
Tell me when would you use a pointer to a function?
Explain the bubble sort algorithm.
what will be the output off the following program? #include<stdio.h> int main() { int a; a=015+0*71+5; printf("%d,a"); return0; }
How can a number be converted to a string?
Do you know the difference between malloc() and calloc() function?
void main() { int a[]={1,2,3,4,5},i; for(i=0;i<5;i++) printf("%d",a++); getch(); }