Concise solution with two heaps
csharp\npublic class MedianFinder\n{\n    PriorityQueue<int, int> left = new();\n    PriorityQueue<int, int> right = new();\n    bool odd = false;\n\n    public
```csharp\npublic class MedianFinder\n{\n    PriorityQueue<int, int> left = new();\n    PriorityQueue<int, int> right = new();\n    bool odd = false;\n\n    public void AddNum(int n)\n    {\n        odd = !odd;\n        int m = right.EnqueueDequeue(n, -n);\n        left.Enqueue(m, m);\n\n        if (left.Count - 1 > right.Count)\n        {\n            m = left.Dequeue();\n            right.Enqueue(m, -m);\n        }\n    }\n    \n    public double FindMedian() =>\n        odd ? left.Peek() : (left.Peek() + right.Peek()) / 2.0;\n}\n```
['Heap (Priority Queue)', 'C#']