8000 minor pep8 updates · coderwxy/book1-exercises@c3d717e · GitHub
[go: up one dir, main page]

Skip to content

Commit c3d717e

Browse files
committed
minor pep8 updates
1 parent e4e619c commit c3d717e

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

refactor/chp14/solutions/14-3.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@
2525
form = login_html.form
2626
form.select("input")[0]["value"] = "wrong"
2727
form.select("input")[1]["value"] = "password"
28-
error_page = my_browser.submit(form, login_page.url) # submit form
28+
error_page = my_browser.submit(form, login_page.url) # submit form
2929

3030
# check for string
3131
if error_page.soup.text.find("Wrong username or password!") != -1:
3232
print("Login Failed.")
3333
else:
34-
print("Login Successful.")
34+
print("Login Successful.")

refactor/chp14/solutions/14-4.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@
77

88
# obtain 1 stock quote per minute for the next 3 minutes
99
for i in range(0, 3):
10-
10+
1111
page = my_browser.get("http://finance.yahoo.com/q?s=yhoo")
1212
html_text = page.soup
13-
13+
1414
# return a list of all the tags where the id is 'yfs_184_yhoo'
1515
my_price_tag = html_text.select("#yfs_l84_yhoo")
1616
# take the BeautifulSoup string out of the first tag
@@ -23,5 +23,5 @@
2323

2424
print("The price of YHOO is: {} on {}".format(my_price, my_time))
2525

26-
if i<2: # wait a minute if this isn't the last request
27-
sleep(60)
26+
if i < 2: # wait a minute if this isn't the last request
27+
sleep(60)

0 commit comments

Comments
 (0)
0