#901 - Online Stock Span
Design a class StockSpanner that collects daily price quotes and returns the span of that day's stock price. The span is the maximum number of consecutive days (starting from today going backward) where the price was less than or equal to today's price.
| Input | Output |
|---|---|
Operations | Output |
next(100), next(80), next(60), next(70), next(60), next(75), next(85) | [1, 1, 1, 2, 1, 4, 6] |