質問編集履歴
5
文の追加
test
CHANGED
File without changes
|
test
CHANGED
@@ -128,7 +128,7 @@
|
|
128
128
|
|
129
129
|
下記が上記のコードで私が解答した正誤が分かる箇所
|
130
130
|
|
131
|
-
つまり、installのほうは正解でorientationは不正解
|
131
|
+
つまり、installのほうは正解でorientation、renownedは不正解
|
132
132
|
|
133
133
|
```False
|
134
134
|
|
4
文の追加
test
CHANGED
File without changes
|
test
CHANGED
@@ -56,48 +56,72 @@
|
|
56
56
|
|
57
57
|
<div data-v-2d259044="" class="result-check-line__icon">
|
58
58
|
|
59
|
-
<div data-v-2d259044="" class="result-check-line__true-false is-true">
|
59
|
+
<div data-v-2d259044="" class="result-check-line__true-false is-true">
|
60
|
+
|
61
|
+
</div>
|
62
|
+
|
63
|
+
</a>
|
64
|
+
|
65
|
+
|
66
|
+
|
67
|
+
|
68
|
+
|
69
|
+
|
70
|
+
|
71
|
+
<a data-v-2d259044="" href="#" class="result-check-line">
|
72
|
+
|
73
|
+
<div data-v-2d259044="" class="result-check-line__main">
|
74
|
+
|
75
|
+
<div data-v-2d259044="" class="result-check-line__main__top">
|
76
|
+
|
77
|
+
<span data-v-2d259044="">orientation</span>
|
78
|
+
|
79
|
+
</div>
|
80
|
+
|
81
|
+
<div data-v-2d259044="" class="result-check-line__main__sub">
|
82
|
+
|
83
|
+
<span data-v-2d259044="">新入社員向け説明会</span>
|
84
|
+
|
85
|
+
</div>
|
86
|
+
|
87
|
+
</div>
|
88
|
+
|
89
|
+
<div data-v-2d259044="" class="result-check-line__icon">
|
90
|
+
|
91
|
+
<div data-v-2d259044="" class="result-check-line__true-false is-false">
|
92
|
+
|
93
|
+
</div>
|
94
|
+
|
95
|
+
</a>
|
96
|
+
|
97
|
+
|
98
|
+
|
99
|
+
<a data-v-2d259044="" href="#" class="result-check-line">
|
100
|
+
|
101
|
+
<div data-v-2d259044="" class="result-check-line__main">
|
102
|
+
|
103
|
+
<div data-v-2d259044="" class="result-check-line__main__top">
|
104
|
+
|
105
|
+
<span data-v-2d259044="">renowned</span>
|
106
|
+
|
107
|
+
</div>
|
108
|
+
|
109
|
+
<div data-v-2d259044="" class="result-check-line__main__sub">
|
110
|
+
|
111
|
+
<span data-v-2d259044="">名高い、著名な</span>
|
112
|
+
|
113
|
+
</div>
|
60
114
|
|
61
115
|
</div>
|
62
116
|
|
117
|
+
<div data-v-2d259044="" class="result-check-line__icon">
|
118
|
+
|
119
|
+
<div data-v-2d259044="" class="result-check-line__true-false is-false">
|
120
|
+
|
121
|
+
</div>
|
122
|
+
|
63
123
|
</a>
|
64
124
|
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
<a data-v-2d259044="" href="#" class="result-check-line">
|
72
|
-
|
73
|
-
<div data-v-2d259044="" class="result-check-line__main">
|
74
|
-
|
75
|
-
<div data-v-2d259044="" class="result-check-line__main__top">
|
76
|
-
|
77
|
-
<span data-v-2d259044="">orientation</span>
|
78
|
-
|
79
|
-
</div>
|
80
|
-
|
81
|
-
<div data-v-2d259044="" class="result-check-line__main__sub">
|
82
|
-
|
83
|
-
<span data-v-2d259044="">新入社員向け説明会</span>
|
84
|
-
|
85
|
-
</div>
|
86
|
-
|
87
|
-
</div>
|
88
|
-
|
89
|
-
<div data-v-2d259044="" class="result-check-line__icon">
|
90
|
-
|
91
|
-
<div data-v-2d259044="" class="result-check-line__true-false is-false"></div>
|
92
|
-
|
93
|
-
</div>
|
94
|
-
|
95
|
-
</div>
|
96
|
-
|
97
|
-
</a>
|
98
|
-
|
99
|
-
|
100
|
-
|
101
125
|
```
|
102
126
|
|
103
127
|
|
@@ -122,6 +146,30 @@
|
|
122
146
|
|
123
147
|
classの部分で抽出するものを分けたいがどうすればいいのかさっぱり
|
124
148
|
|
149
|
+
```python
|
150
|
+
|
151
|
+
from selenium import webdriver
|
152
|
+
|
153
|
+
driver = webdriver.Chrome('chromedriver.exe')
|
154
|
+
|
155
|
+
url = '********'
|
156
|
+
|
157
|
+
driver.get(url)
|
158
|
+
|
159
|
+
|
160
|
+
|
161
|
+
elems_Q = driver.find_elements_by_class_name('result-check-line__main__top')
|
162
|
+
|
163
|
+
elems_Q[0].text #output -> 'install'
|
164
|
+
|
165
|
+
|
166
|
+
|
167
|
+
elems_A = driver.find_elements_by_class_name('result-check-line__main__sub')
|
168
|
+
|
169
|
+
elems_A[0].text #output -> '設置する、導入する'
|
170
|
+
|
171
|
+
```
|
172
|
+
|
125
173
|
###試したこと
|
126
174
|
|
127
175
|
```python
|
@@ -144,7 +192,7 @@
|
|
144
192
|
|
145
193
|
|
146
194
|
|
147
|
-
#理想はここで
|
195
|
+
#理想はここで不正解のみ(orientation, 新入社員向け説明会とrenowned, 名高い、著名な)を出力してほしかった
|
148
196
|
|
149
197
|
elems_F = driver.find_elements_by_class_name('result-check-line__true-false is-false')
|
150
198
|
|
3
文法の修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -144,7 +144,7 @@
|
|
144
144
|
|
145
145
|
|
146
146
|
|
147
|
-
|
147
|
+
#理想はここで'install, 設置する、導入する'と出力してほしかった
|
148
148
|
|
149
149
|
elems_F = driver.find_elements_by_class_name('result-check-line__true-false is-false')
|
150
150
|
|
@@ -152,6 +152,8 @@
|
|
152
152
|
|
153
153
|
#output -> [] 要素がないので当たりですが空っぽ
|
154
154
|
|
155
|
+
|
156
|
+
|
155
157
|
```
|
156
158
|
|
157
159
|
自分でもよくわかっていないので質問が非常に分かりにくくなっていると思いますがよろしくお願いします。
|
2
文法の修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -146,7 +146,7 @@
|
|
146
146
|
|
147
147
|
|
148
148
|
|
149
|
-
elems_F = driver.find_elements_by_class_name('result-check-line__true-false ')
|
149
|
+
elems_F = driver.find_elements_by_class_name('result-check-line__true-false is-false')
|
150
150
|
|
151
151
|
elems_F
|
152
152
|
|
1
文法の修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -128,13 +128,13 @@
|
|
128
128
|
|
129
129
|
#単純な英単語、日本語訳の抽出はできた
|
130
130
|
|
131
|
-
elems_Q =
|
131
|
+
elems_Q = driver.find_elements_by_class_name('result-check-line__main__top')
|
132
132
|
|
133
133
|
elems_Q[0].text #output -> 'install'
|
134
134
|
|
135
135
|
|
136
136
|
|
137
|
-
elems_A =
|
137
|
+
elems_A = driver.find_elements_by_class_name('result-check-line__main__sub')
|
138
138
|
|
139
139
|
elems_A[0].text #output -> '設置する、導入する'
|
140
140
|
|