Back
Close
  • 3988

What will I learn?

In this puzzle, you need to compare values and derivatives then memorize this information while traversing a list.

External resources

Conditions

Learning Opportunities

This puzzle can be solved using the following concepts. Practice using these concepts and improve your skills.

Statement

Given a list of numbers, you have to find not the minimal value but the maximal drop. Be careful that a drop can span on several values!

A higher resolution is required to access the IDE

Story

You sometimes have to take risks buying market shares, and sometimes you have to know when it's time to sell before you lose everything. This is why we propose a little puzzle, to write a program that will do the maths for us, a program in which we can invest all our trust (and money?!).

Don't worry, you won't have to be a market expert, nothing is going to crash.