Question bank › Dynamic Programming
Dsa Dynamic Programming Easy

Jump Game

You are given an array of non-negative integers representing the maximum jump length from that position. Your task is to determine if you can reach the last index starting from the first index. Write a program that reads input and prints 'Yes' if it is possible to reach the end or 'No' otherwise. Input format: - The first line contains an integer n (1 <= n <= 1000) - the number of elements in the array. - The second line contains n integers representing the jump lengths. Output format: - 'Yes' or 'No' Example: Input: 5 2 3 1 1 4 Output: Yes

Key concepts

dynamic_programmingarrays

Practise this out loud — free

Start a mock interview on THIS exact question — a voice AI interviewer opens with it, pushes back like a real onsite, then hands you an instant scorecard.

🎙 Practise this question now
Part of InterviewLab's verified interview question bank. We show the prompt and concepts to practise with — never a copy-paste solution.