C Programming - Pointers - Discussion
Discussion Forum : Pointers - Find Output of Program (Q.No. 20)
20.
What will be the output of the program ?
#include<stdio.h>
int main()
{
char str1[] = "India";
char str2[] = "BIX";
char *s1 = str1, *s2=str2;
while(*s1++ = *s2++)
printf("%s", str1);
printf("\n");
return 0;
}
Discussion:
43 comments Page 4 of 5.
Bharathi said:
1 decade ago
Thanks raju.
It was good explanation.
It was good explanation.
Aravind said:
2 decades ago
How it comes please explain anyone pa.
Vanaja said:
1 decade ago
Thanks raju and anand, subbu.
Emanuel said:
9 years ago
I think it will be BIX.
(1)
Shrinidhi said:
2 decades ago
Someone please explain.
Riswan said:
6 years ago
Thanks to you all.
Praju said:
9 years ago
Well done @Uttam.
Santhosh said:
9 years ago
Thanks Mahendra.
Nishu said:
1 decade ago
Agree wth ramu.
SHIVANI said:
8 years ago
Thank you all.
(1)
Post your comments here:
Quick links
Quantitative Aptitude
Verbal (English)
Reasoning
Programming
Interview
Placement Papers