Reverse a Vector
easynumpy_basicsImplement reverse_vector(x).
Given a 1D array x, return its elements in reverse order (last element
first). Use slicing — no for/while loops.
Constraints
- no for/while loops
Your solution
Edit reverse_vector and run the real pytest suite in your browser — no install required. Your code is saved locally.
Loading the Python runtime (first run only)…
Hints
Hint 1
A slice with a negative step walks the array backwards.