public static void main ( String [ ] args ) throws IOException {
  Scanner in = new Scanner ( new FileReader ( "src/CodeJam/" + inFilename ) ) ;
  PrintWriter out = new PrintWriter ( new FileWriter ( "src/CodeJam/output.txt" ) ) ;
  int T = in . nextInt ( ) ;
  for ( int t = 0 ;
  t < T ;
  t ++ ) {
    String result = "NO" ;
    int N = in . nextInt ( ) ;
    int L = in . nextInt ( ) ;
    int H = in . nextInt ( ) ;
    int [ ] f = new int [ N ] ;
    for ( int i = 0 ;
    i < N ;
    i ++ ) {
      f [ i ] = in . nextInt ( ) ;
    }
    loop : for ( int i = L ;
    i <= H ;
    i ++ ) {
      int j = 0 ;
      for ( ;
      j < N ;
      j ++ ) {
        if ( ! ( f [ j ] % i == 0 || i % f [ j ] == 0 ) ) {
          continue loop ;
        }
      }
      if ( j == N ) {
        result = String . valueOf ( i ) ;
        break ;
      }
    }
    out . print ( "Case #" + ( t + 1 ) + ": " + result + "\n" ) ;
  }
  in . close ( ) ;
  out . close ( ) ;
}

public static void main ( String [ ] args ) throws IOException { Scanner in = new Scanner ( new FileReader ( " src / CodeJam / " + inFilename ) ) ; PrintWriter out = new PrintWriter ( new FileWriter ( " src / CodeJam / output . txt " ) ) ; int T = in . nextInt ( ) ; for ( int t = 0 ; t < T ; t ++ ) { String result = " NO " ; int N = in . nextInt ( ) ; int L = in . nextInt ( ) ; int H = in . nextInt ( ) ; int [ ] f = new int [ N ] ; for ( int i = 0 ; i < N ; i ++ ) { f [ i ] = in . nextInt ( ) ; } loop : for ( int i = L ; i <= H ; i ++ ) { int j = 0 ; for ( ; j < N ; j ++ ) { if ( ! ( f [ j ] % i == 0 || i % f [ j ] == 0 ) ) { continue loop ; } } if ( j == N ) { result = String . valueOf ( i ) ; break ; } } out . print ( " Case ▁ # " + ( t + 1 ) + " : ▁ " + result + " \n " ) ; } in . close ( ) ; out . close ( ) ; }
(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: (string_literal) right: (identifier)))))))) (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 (string_literal))))))) (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 (local_variable_declaration type: (type_identifier) declarator: (variable_declarator name: (identifier) value: (string_literal))) (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: (array_type element: (integral_type) dimensions: (dimensions)) declarator: (variable_declarator name: (identifier) value: (array_creation_expression type: (integral_type) dimensions: (dimensions_expr (identifier))))) (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)))))) (labeled_statement (identifier) (for_statement init: (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (identifier))) 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: (decimal_integer_literal))) (for_statement condition: (binary_expression left: (identifier) right: (identifier)) update: (update_expression (identifier)) body: (block (if_statement condition: (parenthesized_expression (unary_expression operand: (parenthesized_expression (binary_expression left: (binary_expression left: (binary_expression left: (array_access array: (identifier) index: (identifier)) right: (identifier)) right: (decimal_integer_literal)) right: (binary_expression left: (binary_expression left: (identifier) right: (array_access array: (identifier) index: (identifier))) right: (decimal_integer_literal)))))) consequence: (block (continue_statement (identifier)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) consequence: (block (expression_statement (assignment_expression left: (identifier) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (identifier))))) (break_statement)))))) (expression_statement (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (binary_expression left: (binary_expression left: (binary_expression left: (binary_expression left: (string_literal) right: (parenthesized_expression (binary_expression left: (identifier) right: (decimal_integer_literal)))) right: (string_literal)) right: (identifier)) right: (string_literal))))))) (expression_statement (method_invocation object: (identifier) name: (identifier) arguments: (argument_list))) (expression_statement (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))))