Ruby - Arrays
Identify the error in the following Ruby code:
arr = [1, 2, 3, 4, 5] slice = arr[3..1] puts slice.inspect
arr = [1, 2, 3, 4, 5] slice = arr[3..1] puts slice.inspect
15+ quiz questions · All difficulty levels · Free
Free Signup - Practice All Questions