LPTHW 41 - 网址失败

时间:2016-05-20 02:33:14

标签: python-2.7

该脚本包括:

import random  
from urllib import urlopen  
import sys  

WORD_URL = "http://learncodethehardway.org/words.txt"  
WORDS = []  

...  

# load up the words from the website  
for word in urlopen(WORD_URL).readlines():  
    WORDS.append(word.strip())  

...  

当我尝试运行脚本时出现问题。我得到以下回溯: xterm_003.jpg

0 个答案:

没有答案