Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Python基本语法学习/runoob/1helloworld.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/usr/bin/python3
print ("HGello World")
print ("Hello World")


if True:
Expand Down Expand Up @@ -46,4 +46,4 @@


#!/usr/bin/python3
input("\n\n按下 enter 键后退出。")
input("\n\n按下 enter 键后退出。")
4 changes: 2 additions & 2 deletions python网络数据采集/1.2.2BeautifulSoup/scrapetest.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
from bs4 import BeautifulSoup
html = urlopen("http://www.pythonscraping.com/pages/page1.html")
bsObj = BeautifulSoup(html.read(), "html.parser")#
#bsObj = BeautifulSoup(html.read())
bsObj = BeautifulSoup(html.read())
'''
不加"html.parser"会存在警告:UserWarning: No parser was explicitly specified, so I'm using the bes
t available HTML parser for this system ("html.parser"). This usually isn't a problem, but if you run this code on anoth
Expand All @@ -23,4 +23,4 @@
#下面三者产生的结果一样的
print(bsObj.h1)
print(bsObj.html.body.h1)
print(bsObj.html.h1)
print(bsObj.html.h1)