我想打印出这样的xml:
<xml>
<tag>
this is line 1.
this is line 2.
</tag>
</xml>
我有一段代码是这样的:
^{pr2}$但打印出来是这样的:
<xml>
<tag>this is line 1.
this is line 2.</tag>
</xml>
当我使用'\n'
而不是'
'
时,输出如下:
<xml>
<tag>this is line 1. this is line 2.</tag>
</xml>
如何在“this is line 1.”和“this is line 2”之间插入newline
使用'\n'生成新行,即
会产生
^{pr2}$这相当于
相关问题 更多 >
编程相关推荐