以下は、サイドコメントの2つの質問に対する答えを知りたいコードです。私を助けてください
#include<iostream>
using namespace std;
int main()
{
char *p="Hello";
cout <<*p; //gives H
cout <<*(p++); //also gives H.Why?
cout <<*(p++); //gives e.
cout <<*(p++); //gives l.
cout <<*(p++); //gives l.
cout <<*(p++); //gives o.
cout <<*(p++); //gives no output.Why? It should give some garbage value!
}