+ 1

What happens when you use special reserved word as variable name

Variable

10th Sep 2019, 6:41 PM
Ediongsenyene Udoh
Ediongsenyene Udoh - avatar
6 Answers
+ 4
[Edited] here is an example code that causes me a headache to find the problem. print(sum(list(map(int,str(inp2))))) TypeError: 'int' object is not callable https://code.sololearn.com/ccnuDzMG1732/?ref=app
10th Sep 2019, 8:32 PM
Lothar
Lothar - avatar
+ 3
a very short sample from the console: >>> lst = [1,2,3] >>> sum(lst) 6 >>> sum = 0 >>> sum(lst) TypeError: 'int' object is not callable
11th Sep 2019, 6:11 AM
Lothar
Lothar - avatar
0
Error
10th Sep 2019, 6:42 PM
KfirWe
KfirWe - avatar
0
Syntax error
10th Sep 2019, 11:02 PM
Sonic
Sonic - avatar