comefrom: <doocs>0747.Largest Number At Least Twice of Others_1.py
code: def dominantIndex( nums: List[int]) -> int:
      mx = mid = 0
      ans = -1
      for i, v in enumerate(nums):
          if v > mx:
              mid, mx = mx, v
              ans = i
          elif v > mid:
              mid = v
      return ans if mx >= 2 * mid else -1
masked: def sample_funcname ( var_0 : List [ int ] ) -> int :
      var_2 = var_1 = 0
      var_3 = - 1
      for var_4 , var_5 in enumerate ( var_0 ) :
          if var_5 > var_2 :
              var_1 , var_2 = var_2 , var_5
              var_3 = var_4
          elif var_5 > var_1 :
              var_1 = var_5
      return var_3 if var_2 >= 2 * var_1 else - 1
  