static int [ ] findList ( ) {
  int n = sc . nextInt ( ) ;
  int k = sc . nextInt ( ) ;
  int [ ] initial = new int [ n ] ;
  int output [ ] = new int [ 100 ] ;
  for ( int i = 0 ;
  i < n ;
  i ++ ) {
    initial [ i ] = sc . nextInt ( ) ;
  }
  for ( int i = 1 ;
  i <= 100 ;
  i ++ ) {
    int days = 0 ;
    int j = 0 ;
    while ( true ) {
      if ( j >= n ) break ;
      if ( initial [ j ] == i ) {
        j ++ ;
        continue ;
      }
      else {
        j = j + k ;
        days ++ ;
      }
    }
    output [ i - 1 ] = days ;
  }
  return output ;
}

static int [ ] findList ( ) { int n = sc . nextInt ( ) ; int k = sc . nextInt ( ) ; int [ ] initial = new int [ n ] ; int output [ ] = new int [ 100 ] ; for ( int i = 0 ; i < n ; i ++ ) { initial [ i ] = sc . nextInt ( ) ; } for ( int i = 1 ; i <= 100 ; i ++ ) { int days = 0 ; int j = 0 ; while ( true ) { if ( j >= n ) break ; if ( initial [ j ] == i ) { j ++ ; continue ; } else { j = j + k ; days ++ ; } } output [ i - 1 ] = days ; } return output ; }
(method_declaration (modifiers) type: (array_type element: (integral_type) dimensions: (dimensions)) name: (identifier) parameters: (formal_parameters) body: (block (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))) (local_variable_declaration type: (array_type element: (integral_type) dimensions: (dimensions)) declarator: (variable_declarator name: (identifier) value: (array_creation_expression type: (integral_type) dimensions: (dimensions_expr (identifier))))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) dimensions: (dimensions) value: (array_creation_expression type: (integral_type) dimensions: (dimensions_expr (decimal_integer_literal))))) (for_statement init: (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) condition: (binary_expression left: (identifier) right: (identifier)) update: (update_expression (identifier)) body: (block (expression_statement (assignment_expression left: (array_access array: (identifier) index: (identifier)) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))))) (for_statement init: (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) condition: (binary_expression left: (identifier) right: (decimal_integer_literal)) update: (update_expression (identifier)) body: (block (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) (while_statement condition: (parenthesized_expression (true)) body: (block (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) consequence: (break_statement)) (if_statement condition: (parenthesized_expression (binary_expression left: (array_access array: (identifier) index: (identifier)) right: (identifier))) consequence: (block (expression_statement (update_expression (identifier))) (continue_statement)) alternative: (block (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (identifier)))) (expression_statement (update_expression (identifier))))))) (expression_statement (assignment_expression left: (array_access array: (identifier) index: (binary_expression left: (identifier) right: (decimal_integer_literal))) right: (identifier))))) (return_statement (identifier))))