A
Q. What is the output of C program?
Code:
int main()
{
char str1[] = "FIRST";
char str2[20];
strcpy(str2,str1);
printf("%s %s ",str1,str2);
printf("%d", (str1!=str2));
printf("%d", strcmp(str1,str2));
return 0;
}
{
char str1[] = "FIRST";
char str2[20];
strcpy(str2,str1);
printf("%s %s ",str1,str2);
printf("%d", (str1!=str2));
printf("%d", strcmp(str1,str2));
return 0;
}
- Correct Answer - Option(B)
- Views: 24
- Filed under category C Programming
- Hashtags:
Discusssion
Login to discuss.