Q. 52 Consider the following C program:
#include <stdio.h>voidfun1(char*s1,char*s2) {char*temp;temp = s1;s1 = s2;s2 = temp;}voidfun2(char**s1,char**s2) {char*temp;temp = *s1;*s1 = *s2;*s2 = temp;}intmain() {char*str1 ="Hi", *str2 ="Bye";fun1(str1, str2);printf("%s %s", str1, str2);fun2(&str1, &str2);printf("%s %s", str1, str2);return0;}
The output of the program above is
(A) Hi Bye Bye Hi
(B) Hi Bye Hi Bye
(C) Bye Hi Hi Bye
(D) Bye Hi Bye Hi
Answer: (A)
Explanation:












