Question
Computer Science Question on Exception Handling
What kind of build in exception will show by the following code ?
str = ‘Today is holiday’
print(str[20])
A
NameError
B
IndentationError
C
IndexError
D
TypeError
Answer
IndexError
Explanation
Solution
The correct option is () :