Why what exactly? Were you expecting some other result?
1 2 3 4 5 6 7
int main()
{
char *b = "Hello";
printf("%c\n",*b);
printf("Only b is %d\n",sizeof(b));
printf("Pointer b is %d\n",sizeof(*b));
}
Line 3 defines b as a pointer to a string.
Line 4 uses the %c code to output the first character of that string.
Line 5 outputs the size of the pointer.
Line 6 outputs the size of the char.
Another example:
1 2 3 4
char a[] = "World!";
printf("%s\n", a);
printf("Array a size %d\n", sizeof(a));
printf("String a size %d\n", strlen(a));