10 XP challenge

Find the Last Exact Match

easy
Build it yourself · 6 min
1 Learn2 Predict3 Solve

Task
Your mission

Return the last zero-based index where numbers equals target, or -1 when absent. numbers contains 0 to 30 integers from -100 to 100; target is in that range.

Examples

InputReturn
numbers = [4,2,4], target = 4

found: -1 → 0 → 2. The result is 2.

2
numbers = [1,2,3], target = 2

found: -1 → 1. The result is 1.

1

Your code

Write your answer inside Solution, then use return to send it back.

Try examples runs the public examples. Check my code checks your full answer and saves your completion.