Solution using lambda in python
IDEA:\n1. Sort envelopes according to width or you can sort height also.\n2. Now , find Longest Increasing Subsequence of height or width(if you sort envelopes 
IDEA:\n1. Sort envelopes according to width or you can sort height also.\n2. Now , find Longest Increasing Subsequence of height or width(if you sort envelopes according to height).\n3. Your answer will be length of Longest Increasing Subsequence.\n\n***Note**: I have used DP to find LIS with complexity O(n^2) you can also use binary approach which leads to O(nlogn).*\n```\ndef maxEnvelopes(self, envelopes: List[List[int]]) -> int:\n        if not envelopes:\n            return 0\n        envelopes = sorted(envelopes,key=lambda envelop:(envelop[0],-1*envelop[1]))\n        return self.LIS(envelopes)\n\n    def LIS(self,envelopes):\n        lis = [1]*len(envelopes)\n        res = 1\n        for i in range(1,len(envelopes)):\n            for j in range(0,i):\n                if(envelopes[j][1] < envelopes[i][1] and lis[i]<lis[j]+1):\n                    lis[i] = lis[j]+1\n            if res < lis[i]:\n                res = lis[i]\n        return res\n```\nStill facing difficulties, comment below.\nYou can upvote too. :)
['Array', 'Dynamic Programming', 'Sorting', 'Python3']