The quiz where the difficulty automagically adapts to the player's Python knowledge
This is a question page. You can use this page to bookmark a question. Start a new quiz!
Question #97
"python"[-2:1:-1]
The slice notation step goes as per the following: a[start:stop:step]. Here, the slide start at -2 (before "t"), stops as -1 (before "n") as the step is -1. (stackoverflow.com/questions/509211/understanding-slice-no...)
What is the output of the code snippet below?
— The Python Quiz (@thepythonquiz) April 20, 2020
"python"[-2:1:-1]
oht
tho
o
th#python #pythonprogramming
Question difficulty: π΅π΅π΅π΅π΅
Similar questions: