user image

Preeti Tripathi

Job Interview Skills
English
2 years ago

43. Define Python Slicing

user image

Abhishek Mishra

2 years ago

Accessing individual elements of sequences such as lists, tuples, and strings is done using slicing. Slicing has the syntax [ start:end:step]. The action may also be skipped. When we write [start: end], it returns all of the sequence's members up until element end-1, inclusive. It means the ith element from the end if either the start or end element is negative i. The step describes the jump or the number of components that must be omitted. For instance,

Recent Doubts

Close [x]