python - 为什么这行代码有一个反斜杠作为输出?
问题描述
>>> 'She said, "That' + "'" + 's hard to read."'
'She said, "That\'s hard to read."'
为什么这行代码在输出中有反斜杠?
解决方案
推荐阅读
- python-3.x - Tensorflow 2.1 TPU v2 使用 bfloat16 减少内存使用
- php - Twilio 未捕获的 Twilio\Exceptions\RestException:[HTTP 401] 无法获取记录:
- swift - 导航栏按钮有时不可点击
- angular - 带有验证的 Angular 反应表单:错误类型错误:无法读取未定义的属性“firstName”
- python - 为什么这个 Python 嵌套的 for 循环会产生我得到的输出?
- apache-spark - Gcloud 计算 ssh --zone=us-east1-d --ssh-flag="-D" --ssh-flag="10000" --ssh-flag="-N" "spark-01-m" 不是在职的
- crystal-reports - Crystal Report 不显示数据库中的当前记录
- algorithm - 什么是项目列表的“最佳”顺序,以最小化取决于其顺序的成本函数
- android - 如何在 mediastorage android 中写入/读取视频媒体文件?
- r - 编写包时在 R 中找不到文件:正确的方法是什么?