回答編集履歴
4
list化
test
CHANGED
@@ -10,13 +10,13 @@
|
|
10
10
|
|
11
11
|
|
12
12
|
|
13
|
-
split_texts = map(lambda x: x.split(','), text_box1.split('\n'))
|
13
|
+
split_texts = list(map(lambda x: x.split(','), text_box1.split('\n')))
|
14
14
|
|
15
15
|
# split_texts = []
|
16
16
|
|
17
17
|
# for s in text_box1.split('\n'): #=> 改行コードで分割
|
18
18
|
|
19
|
-
# split_texts.append(s.split(',') #=> カンマで分割
|
19
|
+
# split_texts.append(s.split(',')) #=> カンマで分割
|
20
20
|
|
21
21
|
|
22
22
|
|
3
無駄な内包表記削除
test
CHANGED
@@ -10,7 +10,15 @@
|
|
10
10
|
|
11
11
|
|
12
12
|
|
13
|
-
split_texts =
|
13
|
+
split_texts = map(lambda x: x.split(','), text_box1.split('\n'))
|
14
|
+
|
15
|
+
# split_texts = []
|
16
|
+
|
17
|
+
# for s in text_box1.split('\n'): #=> 改行コードで分割
|
18
|
+
|
19
|
+
# split_texts.append(s.split(',') #=> カンマで分割
|
20
|
+
|
21
|
+
|
14
22
|
|
15
23
|
|
16
24
|
|
2
元データ追加
test
CHANGED
@@ -1,4 +1,14 @@
|
|
1
1
|
```python
|
2
|
+
|
3
|
+
text_box1 = """12.730,540.827
|
4
|
+
|
5
|
+
12.733,540.830
|
6
|
+
|
7
|
+
12.758,540.856
|
8
|
+
|
9
|
+
12.759,540.857"""
|
10
|
+
|
11
|
+
|
2
12
|
|
3
13
|
split_texts = [[i for i in j] for j in map(lambda x: x.split(','), text_box1.split('\n'))]
|
4
14
|
|
1
typo
test
CHANGED
@@ -10,9 +10,9 @@
|
|
10
10
|
|
11
11
|
r = []
|
12
12
|
|
13
|
-
for text in split_texts:
|
13
|
+
for texts in split_texts:
|
14
14
|
|
15
|
-
r.append(text[i])
|
15
|
+
r.append(texts[i])
|
16
16
|
|
17
17
|
result.append(r)
|
18
18
|
|