public static void main ( String [ ] args ) throws FileNotFoundException {
  Scanner s = new Scanner ( new File ( inputDirectory + inputFile ) ) ;
  output = new PrintWriter ( new File ( inputDirectory + outputFile ) ) ;
  int cases = s . nextInt ( ) ;
  for ( int Case = 1 ;
  Case <= cases ;
  Case ++ ) {
    s . nextLine ( ) ;
    int googlers = s . nextInt ( ) ;
    int maxSupriseScores = s . nextInt ( ) ;
    int targetScore = s . nextInt ( ) ;
    int normalScores = 0 ;
    int surpriseScores = 0 ;
    for ( int i = 0 ;
    i < googlers ;
    i ++ ) {
      int score = s . nextInt ( ) ;
      if ( targetScore > score ) {
        continue ;
      }
      int otherScore = ( score - targetScore ) / 2 ;
      if ( otherScore >= targetScore - 1 ) {
        normalScores ++ ;
      }
      else if ( otherScore >= targetScore - 2 ) {
        surpriseScores ++ ;
      }
    }
    int answer = normalScores + Math . min ( surpriseScores , maxSupriseScores ) ;
    out ( "Case #" + Case + ": " + answer ) ;
  }
  output . flush ( ) ;
}

public static void main ( String [ ] args ) throws FileNotFoundException { Scanner s = new Scanner ( new File ( inputDirectory + inputFile ) ) ; output = new PrintWriter ( new File ( inputDirectory + outputFile ) ) ; int cases = s . nextInt ( ) ; for ( int Case = 1 ; Case <= cases ; Case ++ ) { s . nextLine ( ) ; int googlers = s . nextInt ( ) ; int maxSupriseScores = s . nextInt ( ) ; int targetScore = s . nextInt ( ) ; int normalScores = 0 ; int surpriseScores = 0 ; for ( int i = 0 ; i < googlers ; i ++ ) { int score = s . nextInt ( ) ; if ( targetScore > score ) { continue ; } int otherScore = ( score - targetScore ) / 2 ; if ( otherScore >= targetScore - 1 ) { normalScores ++ ; } else if ( otherScore >= targetScore - 2 ) { surpriseScores ++ ; } } int answer = normalScores + Math . min ( surpriseScores , maxSupriseScores ) ; out ( " Case ▁ # " + Case + " : ▁ " + answer ) ; } output . flush ( ) ; }
(method_declaration (modifiers) type: (void_type) name: (identifier) parameters: (formal_parameters (formal_parameter type: (array_type element: (type_identifier) dimensions: (dimensions)) name: (identifier))) (throws (type_identifier)) body: (block (local_variable_declaration type: (type_identifier) declarator: (variable_declarator name: (identifier) value: (object_creation_expression type: (type_identifier) arguments: (argument_list (object_creation_expression type: (type_identifier) arguments: (argument_list (binary_expression left: (identifier) right: (identifier)))))))) (expression_statement (assignment_expression left: (identifier) right: (object_creation_expression type: (type_identifier) arguments: (argument_list (object_creation_expression type: (type_identifier) arguments: (argument_list (binary_expression left: (identifier) right: (identifier)))))))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (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: (identifier)) update: (update_expression (identifier)) body: (block (expression_statement (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: (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: (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))) (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 (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) consequence: (block (continue_statement))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) right: (decimal_integer_literal)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (binary_expression left: (identifier) right: (decimal_integer_literal)))) consequence: (block (expression_statement (update_expression (identifier)))) alternative: (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (binary_expression left: (identifier) right: (decimal_integer_literal)))) consequence: (block (expression_statement (update_expression (identifier)))))))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (binary_expression left: (identifier) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (identifier) (identifier)))))) (expression_statement (method_invocation name: (identifier) arguments: (argument_list (binary_expression left: (binary_expression left: (binary_expression left: (string_literal) right: (identifier)) right: (string_literal)) right: (identifier))))))) (expression_statement (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))))