C++ cout char *

来源:互联网 发布:ipad画图软件免费 编辑:程序博客网 时间:2024/06/05 07:34
const char * p = "hello";cout<<p<<endl;

cout输出char *类型的时候一定要加endl,不然没有结束标志,至于原理,暂时也没细看。

原创粉丝点击