PYTHON || EASY SOLUTION || SIMPLE CODE || SORTING
\n\n    def init(self):\n\n        self.lst=[]       \'\'\'insted of using list we can also use sorted array from library then its time complexity reduces to nl
\n\n    def __init__(self):\n\n        self.lst=[]       \'\'\'insted of using list we can also use sorted array from library then its time complexity reduces to nlogn to logn then we dont have to sort it\'\'\'\n\n    def addNum(self, num: int) -> None:\n        self.lst.append(num)\n\n    def findMedian(self) -> float:\n        self.lst.sort()\n        mid=len(self.lst)//2\n        if len(self.lst)%2==0:\n            return (self.lst[mid-1]+self.lst[mid])/2\n        else:\n            return self.lst[mid]
['Math', 'Sorting', 'Python']