随笔

#include <stdio.h>
#include <string.h>
#include <iostream>
int main()
{
    char* p = "123";
    printf("%d\n", sizeof(p));//4
    printf("%d\n", strlen(p));//3
    std::cout << p + 1;//"23"
    return 0;
}

 

posted @ 2017-01-04 22:32  zzyoucan  阅读(94)  评论(0编辑  收藏  举报