comefrom: <awangdev>496. Next Greater Element I_1.java
code: private Map<Integer, Integer> generateSubMap(int[] base) {
  
          Stack<Integer> stack = new Stack<>();
          Map<Integer, Integer> baseMap = new HashMap<>();
          for (int num : base) {
              while (!stack.isEmpty() && stack.peek() < num) {
                  int pop = stack.pop();
                  baseMap.put(pop, num);
              }
              stack.push(num);
          }
          return baseMap;
      }
masked: private Map < Integer , Integer > var_0 ( int [ ] var_1 ) {
    Stack < Integer > var_2 = new Stack < > ( ) ;
    Map < Integer , Integer > var_3 = new HashMap < > ( ) ;
    for ( int var_4 : var_1 ) {
      while ( ! var_2 . isEmpty ( ) && var_2 . peek ( ) < var_4 ) {
        int pop = var_2 . pop ( ) ;
        var_3 . put ( pop , var_4 ) ;
      }
      var_2 . push ( var_4 ) ;
    }
    return var_3 ;
  }
  