任何人都可以帮助我使用此代码吗?
Jobs = ()
openFile = open('Jobs.txt')
x = 1
while x != 0:
Stuff = openFile.readline(x)
if Stuff != '':
Jobs.append(Stuff)
else:
x = 0
Run Code Online (Sandbox Code Playgroud)
此代码抛出:
AttributeError: 'tuple' object has no attribute 'append'
Run Code Online (Sandbox Code Playgroud)
我正在使用 Python 3.6。