Easy
Slicing Arrays
Read integers into an array. Print
a[::-1], a[1:-1] and a[::2] as lists, one per line.Input
One line of integers.
Output
Three lists.
Sample 1
Input
1 2 3 4 5
Output
[5, 4, 3, 2, 1] [2, 3, 4] [1, 3, 5]
Sample 2
Input
7 8
Output
[8, 7] [] [7]
Output appears here