Maison  >  Questions et réponses  >  le corps du texte

c++ - char* p = "123\0123";这是什么意思?

char* p = "123\0123";
cout << strlen(p) << endl;//5

求解释!

怪我咯怪我咯2714 Il y a quelques jours566

répondre à tous(2)je répondrai

  • 巴扎黑

    巴扎黑2017-04-17 15:33:52

    http://en.cppreference.com/w/...

    \012 是一个字符,ASCII 码为 10

    répondre
    0
  • 黄舟

    黄舟2017-04-17 15:33:52

    这个东西关于转义字符
    换行 \n \12
    希望我没说错

    répondre
    0
  • Annulerrépondre