881. 救生艇
class Solution:
    def numRescueBoats(self, people: List[int], limit: int) -> int:
        people.sort()
        n = len(people)
        l, r = 0, n-1
        
        while l <= r:
            if people[l] + people[r] <= limit:
                l += 1     
            
            r -= 1
            
        return n - 1 - r