<awangdev>739. Daily Temperatures_2.java
public int[] dailyTemperatures(int[] T) {
        int n = T.length;
        int[] rst = new int[n];
        Integer[] tempIndex = new Integer[101]; 
        
        for (int i = n - 1; i >= 0; i--) {
            int num = T[i], warmerIndex = Integer.MAX_VALUE;;
            
            for (int t = num + 1; t <= 100; t++) { 
                if (tempIndex[t] != null && tempIndex[t] < warmerIndex) warmerIndex = tempIndex[t];
            }
            
            if (warmerIndex < Integer.MAX_VALUE) rst[i] = warmerIndex - i; 
            tempIndex[num] = i;
        }
        
        return rst;
    }
public int [ ] sample_funcname ( int [ ] var_0 ) {
  int var_2 = var_0 . length ;
  int [ ] var_3 = new int [ var_2 ] ;
  Integer [ ] var_6 = new Integer [ 101 ] ;
  for ( int var_8 = var_2 - 1 ;
  var_8 >= 0 ;
  var_8 -- ) {
    int var_10 = var_0 [ var_8 ] , var_12 = Integer . MAX_VALUE ;
    ;
    for ( int var_13 = var_10 + 1 ;
    var_13 <= 100 ;
    var_13 ++ ) {
      if ( var_6 [ var_13 ] != null && var_6 [ var_13 ] < var_12 ) var_12 = var_6 [ var_13 ] ;
    }
    if ( var_12 < Integer . MAX_VALUE ) var_3 [ var_8 ] = var_12 - var_8 ;
    var_6 [ var_10 ] = var_8 ;
  }
  return var_3 ;
}
