<qiyuangong>1365_How_Many_Numbers_Are_Smaller_Than_the_Current_Number_1.java
public int[] smallerNumbersThanCurrent(int[] nums) {
        int[] countList = new int[101];
        int[] res = new int[nums.length];
        for (int i = 0; i < nums.length; i++)
            countList[nums[i]]++;
        for (int i = 1; i < 101; i++)
            countList[i] += countList[i-1];
        for (int i = 0; i < nums.length; i++) {
            if (nums[i] == 0) res[i] = 0;
            else res[i] = countList[nums[i]-1];
        }
        return res;
    }
public int [ ] sample_funcname ( int [ ] var_0 ) {
  int [ ] var_2 = new int [ 101 ] ;
  int [ ] var_4 = new int [ var_0 . length ] ;
  for ( int var_6 = 0 ;
  var_6 < var_0 . length ;
  var_6 ++ ) var_2 [ var_0 [ var_6 ] ] ++ ;
  for ( int var_6 = 1 ;
  var_6 < 101 ;
  var_6 ++ ) var_2 [ var_6 ] += var_2 [ var_6 - 1 ] ;
  for ( int var_6 = 0 ;
  var_6 < var_0 . length ;
  var_6 ++ ) {
    if ( var_0 [ var_6 ] == 0 ) var_4 [ var_6 ] = 0 ;
    else var_4 [ var_6 ] = var_2 [ var_0 [ var_6 ] - 1 ] ;
  }
  return var_4 ;
}
