comefrom: <awangdev>Summary Ranges_1.java
code: public List<String> summaryRanges(int[] nums) {
       List<String> rst = new ArrayList<>();
       if (nums == null || nums.length == 0) {
       	return rst;
       }   
       List<Integer> list = new ArrayList<>();
       for (int i = 0; i < nums.length; i++) {
       	list.add(nums[i]);
       	if (i + 1 == nums.length || nums[i] + 1 != nums[i + 1]) {
       		if (list.size() == 1) {
       			rst.add(list.get(0) + "");
       		} else {
       			rst.add(list.get(0) + "->" + list.get(list.size() - 1));
       		}
       		list = new ArrayList<Integer>();
       	}
       }
       return rst;
      }
masked: public List < String > var_0 ( int [ ] var_1 ) {
    List < String > var_2 = new ArrayList < > ( ) ;
    if ( var_1 == null || var_1 . length == 0 ) {
      return var_2 ;
    }
    List < Integer > var_3 = new ArrayList < > ( ) ;
    for ( int var_4 = 0 ;
    var_4 < var_1 . length ;
    var_4 ++ ) {
      var_3 . add ( var_1 [ var_4 ] ) ;
      if ( var_4 + 1 == var_1 . length || var_1 [ var_4 ] + 1 != var_1 [ var_4 + 1 ] ) {
        if ( var_3 . size ( ) == 1 ) {
          var_2 . add ( var_3 . get ( 0 ) + "" ) ;
        }
        else {
          var_2 . add ( var_3 . get ( 0 ) + "->" + var_3 . get ( var_3 . size ( ) - 1 ) ) ;
        }
        var_3 = new ArrayList < Integer > ( ) ;
      }
    }
    return var_2 ;
  }
  