Stock Market Problem

Below is Java code that implements three different solutions for the Stock Market problem: