Vidyalelo
C Programming · Q224

Pointer

Programming · C Programming · question 224

Q224

What will be the output of the following C code? #include int main() char str[] = "hello, world"; str[5] = '.'; printf("%s ", str); return 0;

A.
hello. world
Answer
B.
hello, world
C.
Compile error
D.
Segmentation fault

Answer: Option A

Solution

Answer: Option A
No explanation is given for this question Let's Discuss on Board