c++11 原生字符串字面值

c++11 原生字符串字面值

#define _CRT_SECURE_NO_WARNINGS

#include <iostream>
#include <string>
#include <vector>
#include <map>


void mytest()
{
    /*
    原生字符串字面值(raw string literal)使用户书写的字符串“所见即所得”。
    C++11中原生字符串的声明相当简单,只需在字符串前加入前缀,即字母R,并在引号中使用括号左右标识,就可以声明该字符串字面量为原生字符串了。
    */
    std::cout << R"(hello,

        world)" << std::endl;

    return;
}


int main()
{
    mytest();

    system("pause");
    return 0;
}
原文地址:https://www.cnblogs.com/lsgxeva/p/7787376.html