urllib can't run | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

urllib can't run

import request from urllib if __name__ == "__main__": response =request.urlopen("http://www.baidu.com") html = response.read() print(html)

17th Apr 2018, 10:33 AM
Jimu
Jimu - avatar
2 Answers
+ 13
what should be the output ??? is this what u wanted Run again if it shows time limit exceed i have made some changes 👇 https://code.sololearn.com/cdPLa1RYbC9E/?ref=app
17th Apr 2018, 10:46 AM
🌛DT🌜
🌛DT🌜 - avatar
0
Greetings! Your import statement is wrong, the syntax the following: from module import something
18th Apr 2018, 5:16 AM
Alexandr Pismenskii
Alexandr Pismenskii - avatar