Let me add comments to the code to help explain what's happening.
#include<stdio.h>
void main()
{
char *ptr, k='p';
//this creates two variables:
//ptr, which accepts the address of a char as its contents, is unitialized, and is located someplace (let's say at 0x1234000A)
//k, which accepts a char as its contents, is initialized to 'p', and is located someplace (let's say at 0x1234000C)
ptr=&k;
//This updates the contents of ptr to the address of k, 0x1234000C
printf("%c",*ptr);
//*ptr is the variable located at 0x1234000C, or k, and it's contents, 'p', are printed
char* cp;
//this creates another variable, cp, which accepts the address of a char, is unitialized, and is located someplace (let's say at 0x1234000D)
char c[9]={"adsf"};
//this creates an array of 9 chars with the following information:
//c[0] accepts a char, is initialized to 'a', and is located someplace (let's say at 0x1234000F)
//c[1] accepts a char, is initialized to 'd', and is located someplace (let's say at 0x12340010)
//c[2] accepts a char, is initialized to 's', and is located someplace (let's say at 0x12340011)
//c[3] accepts a char, is initialized to 'f', and is located someplace (let's say at 0x12340012)
//c[4] accepts a char, is initialized to '\0', and is located someplace (let's say at 0x12340013)
//c[5] accepts a char, is initialized to '\0', and is located someplace (let's say at 0x12340014)
//c[6] accepts a char, is initialized to '\0', and is located someplace (let's say at 0x12340015)
//c[7] accepts a char, is initialized to '\0', and is located someplace (let's say at 0x12340016)
//c[8] accepts a char, is initialized to '\0', and is located someplace (let's say at 0x12340017)
//c is treated as a pointer to c[0], that is, it returns 0x1234000F
cp=&c[0];
//cp is set to 0x1234000F
//printf("%s",*cp); <-- it is showing general protection error
//this would throw an error, because you dereference cp and attempt to print the string located in memory located at the address of the integer representation of character 'a'. Usually, this is OUTSIDE YOUR PROGRAM, and probably inside OS memory, which is protected.
printf("%s", cp); //this is equivalent to printf("%s", c);
}