Created
May 12, 2020 15:57
-
-
Save ohbadiah/8019503cf1fca9969dd483b704207849 to your computer and use it in GitHub Desktop.
Algorithm practice #2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
You are given an array of integers. | |
Can you find the maximum difference between any two integers in the array, | |
with the restriction that the larger integer follows the smaller one? | |
For example: | |
[7 8 9 4 3 1 2] => 2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment