+ 1

What is this python error?

What is this error? Traceback (most recent call last): File "..\Playground\", line 17, in <module> vars.append[code[i].split(" ")[1]] TypeError: 'builtin_function_or_method' object is not subscriptable also, how do I fix it? Thanks!

7th Jun 2019, 11:51 PM
Adler Vuong
Adler Vuong - avatar
2 ответов
+ 3
vars.append([code[i].split(" ")[1]) If that doesn't work please share the code you're talking about.
8th Jun 2019, 1:22 AM
Diego
Diego - avatar
+ 3
That works, thank you!
8th Jun 2019, 1:33 AM
Adler Vuong
Adler Vuong - avatar