comefrom: <doocs>1626.Best Team With No Conflicts_1.py
code: def bestTeamScore( scores: List[int], ages: List[int]) -> int:
      nums = list(zip(ages, scores))
      nums.sort()
      n = len(nums)
      dp = [num[1] for num in nums]
      for i in range(n):
          for j in range(i):
              if nums[i][1] >= nums[j][1]:
                  dp[i] = max(dp[i], dp[j] + nums[i][1])
      return max(dp)
masked: def sample_funcname ( var_0 : List [ int ] , var_1 : List [ int ] ) -> int :
      var_2 = list ( zip ( var_1 , var_0 ) )
      var_2.sort ( )
      var_3 = len ( var_2 )
      var_5 = [ var_4 [ 1 ] for var_4 in var_2 ]
      for var_6 in range ( var_3 ) :
          for var_7 in range ( var_6 ) :
              if var_2 [ var_6 ] [ 1 ] >= var_2 [ var_7 ] [ 1 ] :
                  var_5 [ var_6 ] = max ( var_5 [ var_6 ] , var_5 [ var_7 ] + var_2 [ var_6 ] [ 1 ] )
      return max ( var_5 )
  