Challenge: Slicing with Index Function
Swipe to start coding
Try to extract words using slicing, but in a little bit more complicated way. The syntax of slicing is the following:
word[start_index:end_index]
To find the start_index, use the index() method, and to find the end_index, use the index() method, and add the length of the word.
- Extract the word
painful. - Extract the word
mistakes. - Extract the word
learn.
If you use all the methods that were explored, this task won't be challenging for you.
Solução
Obrigado pelo seu feedback!
single
Pergunte à IA
Pergunte à IA
Pergunte o que quiser ou experimente uma das perguntas sugeridas para iniciar nosso bate-papo
Can you explain this in more detail?
What are the next steps I should take?
Can you give me an example?
Awesome!
Completion rate improved to 3.03
Challenge: Slicing with Index Function
Deslize para mostrar o menu
Swipe to start coding
Try to extract words using slicing, but in a little bit more complicated way. The syntax of slicing is the following:
word[start_index:end_index]
To find the start_index, use the index() method, and to find the end_index, use the index() method, and add the length of the word.
- Extract the word
painful. - Extract the word
mistakes. - Extract the word
learn.
If you use all the methods that were explored, this task won't be challenging for you.
Solução
Obrigado pelo seu feedback!
single