回答編集履歴

1

修正

2019/08/05 07:06

投稿

LouiS0616
LouiS0616

スコア35660

test CHANGED
@@ -1,4 +1,4 @@
1
- 諦めて`r"t67890-^\"`と書くしか無いです。
1
+ ~~諦めて`r"t67890-^\"`と書くしか無いです。~~
2
2
 
3
3
 
4
4
 
@@ -8,4 +8,20 @@
8
8
 
9
9
 
10
10
 
11
+ > ...中略
12
+
13
+
14
+
15
+ > ```Python
16
+
17
+ dir = r"\this\is\my\dos\dir" "\"
18
+
19
+ dir = r"\this\is\my\dos\dir\ "[:-1]
20
+
21
+ dir = "\this\is\my\dos\dir\"
22
+
23
+ > ```
24
+
25
+
26
+
11
27
  **引用元:** [デザインと歴史 FAQ — Python 3.7.4 ドキュメント](https://docs.python.org/ja/3/faq/design.html#why-can-t-raw-strings-r-strings-end-with-a-backslash)