python是否有换行符,例如HTML中有<br>

问题描述

python中是否有换行符?我知道我可以放一个print(“”)来换行,但是python中有换行符的属性吗?

解决方法

使用\n

例如print('line1\nline2')

阅读escape sequences