Examveda
Examveda

What will be the output of the following C code?
#include <stdio.h>
void f(char *k)
{
    k++;
    k[2] = 'm';
}
void main()
{
    char s[] = "hello";
    f(s);
    printf("%c\n", *s);
}

A. h

B. e

C. m

D. o;

Answer: Option A


This Question Belongs to C Program >> Pointer

Join The Discussion

Related Questions on Pointer