2024-03-28 19:28:14 发布
网友
我在终端的macbook上输入python3自动.py. 没有打印到终端。下面是我的python代码:
import nltk raw_words = open("words.py").read() raw_words.close() print(raw_words)
请帮忙
试试这个:
filename = "words.py" with open(filename,'rb',encoding="utf-8") as fp: raw_words = fp.read() print(raw_words)
尝试:import nltk raw_words = open("words.py").read() print(raw_words)
import nltk raw_words = open("words.py").read() print(raw_words)
试试这个:
尝试:
import nltk raw_words = open("words.py").read() print(raw_words)
相关问题 更多 >
编程相关推荐