Q. What is the output of ‘Python'[1:4]?
Solution:
[1:4] slices from index 1 to 3 (exclusive), returning ‘ytho’.
Get Question Bank
Strengthen Your Practice with our comprehensive question bank.
[1:4] slices from index 1 to 3 (exclusive), returning ‘ytho’.
Strengthen Your Practice with our comprehensive question bank.