← Back to Difficulty Selection

Code Review (Easy): Pipeline Momentum Check

Story

Lena is building a tool for our internal deployment pipeline to see if a release can actually reach the final production stage. Each checkpoint in the pipeline provides a specific amount of momentum that determines how many steps forward it can push the process. Mark asked her to create a helper to verify if a sequence of these checkpoints contains a path that successfully reaches the last stage. For instance, if the sequence is [2, 3, 1, 1, 4], you could jump from the start to the second spot and then straight to the end, but a sequence like [3, 2, 1, 0, 4] would leave you stuck at a dead end.

Your Task

Read the story and code, then decide if the code is ready for production or needs improvement.

Hints

What would block an approval? Give me a hint.

Next

Check out Next Topic: The Dashboard Banner Layout

Cookies help us track your progress - nothing extra.