+ 6

Why Pyrhon doesn't see variable b (line 12)?

https://code.sololearn.com/cbA8GtBXcRIy/?ref=app

13th May 2019, 5:21 PM
Ilya R
Ilya R - avatar
2 Respuestas
+ 5
num2 is a list and num is an int so num == num2 returns False
13th May 2019, 6:34 PM
Mert Yazıcı
Mert Yazıcı - avatar
+ 3
As Mert already mentioned, your function look_for_pol() returns False. This is then assigned to b. if b == True does fail to append b to list result, results is an empty list that creates an error by trying to use the max() function. So review line 3 and 4 of your function look_for_pol().
13th May 2019, 7:16 PM
Lothar
Lothar - avatar
En tendencia hoy
.
1 Votes
What?
0 Votes
HTML
0 Votes
Web
0 Votes
Quiz duel
0 Votes
FRC Coding?
1 Votes
help
0 Votes
AI
2 Votes
APIs
1 Votes