The median is the middle value in an ordered integer list. Design a data structure that supports the following two operations:
void addNum(int num)- Add an integer number from the data stream to the data structure.double findMedian()- Return the median of all elements so far.
- Method calls.
Input: ["MedianFinder", "addNum", "addNum", "findMedian", "addNum", "findMedian"] [[], [1], [2], [], [3], []]
Output: [null, null, null, 1.5, null, 2.0]