For other types, such as integers, indexing them isn't possible, and it causes a TypeError. | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

For other types, such as integers, indexing them isn't possible, and it causes a TypeError.

can somebody please explain this with example?

16th Aug 2017, 2:28 PM
Nityanand
1 Answer
0
hi, indexing is possible only with string not with other data type like int, float etc.. so it throws exception like type error
3rd Sep 2017, 12:57 PM
Nanda Balakrishnan