[python-error] TypeError: list indices must be integers or slices, not NoneType

lheunΒ·2022λ…„ 9μ›” 8일
0

python-error

λͺ©λ‘ 보기
1/1
post-thumbnail

🚨 λ°œμƒ 였λ₯˜

TypeError: list indices must be integers or slices, not NoneType

βœ… 였λ₯˜ λ°œμƒ 이유

  • 리슀트λ₯Ό 인덱싱할 λ•Œ μ •μˆ˜κ°€ μ•„λ‹Œ λ¬Έμžμ—΄λ‘œ 인덱싱할 λ•Œ λ°œμƒν•œλ‹€

ν˜ΈμΆœν•œ ν•¨μˆ˜μ— return을 μž…λ ₯해주지 μ•Šμ•„μ„œ None이 λ“€μ–΄κ°€μ„œ 였λ₯˜κ°€ 났닀

πŸ‘ Reference

[Python error] typeError: list indices must be integers or slices, not str

profile
πŸ›«

0개의 λŒ“κΈ€