When I change letter g to p and try to output the string it gives seg fault error. Why? Thanks.Code:#include <stdio.h> #include <stdlib.h> #include <string.h> int main() { char** ptr=(char**)malloc(2*sizeof(char*)); ptr[0]=(char*)malloc(10*sizeof(char)); ptr[1]=(char*)malloc(10*sizeof(char)); ptr[1]="goodnight"; *(ptr[1])='p'; puts(ptr[1]); }