Skip to content

Latest commit

 

History

History
15 lines (11 loc) · 276 Bytes

slicing_lvl_2.md

File metadata and controls

15 lines (11 loc) · 276 Bytes

Slicing - Level 2

What is the result of each of the following statements if x = 'abcdefgh'

  1. x[-1:-2]
  2. x[3:-1]
  3. x[::1]
  4. x[::3]
  5. x[1:2:3]
  6. x[::-1]
  7. x[1::-1]

Solution

Click here to view the solution.