static int maxAtLevel ( Node root , int level ) {
  if ( root == null ) return 0 ;
  if ( level == 0 ) return root . data ;
  int x = maxAtLevel ( root . left , level - 1 ) ;
  int y = maxAtLevel ( root . right , level - 1 ) ;
  return Math . max ( x , y ) ;
}

static int maxAtLevel ( Node root , int level ) { if ( root == null ) return 0 ; if ( level == 0 ) return root . data ; int x = maxAtLevel ( root . left , level - 1 ) ; int y = maxAtLevel ( root . right , level - 1 ) ; return Math . max ( x , y ) ; }
(method_declaration (modifiers) type: (integral_type) name: (identifier) parameters: (formal_parameters (formal_parameter type: (type_identifier) name: (identifier)) (formal_parameter type: (integral_type) name: (identifier))) body: (block (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (null_literal))) consequence: (return_statement (decimal_integer_literal))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (decimal_integer_literal))) consequence: (return_statement (field_access object: (identifier) field: (identifier)))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (method_invocation name: (identifier) arguments: (argument_list (field_access object: (identifier) field: (identifier)) (binary_expression left: (identifier) right: (decimal_integer_literal)))))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (method_invocation name: (identifier) arguments: (argument_list (field_access object: (identifier) field: (identifier)) (binary_expression left: (identifier) right: (decimal_integer_literal)))))) (return_statement (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (identifier) (identifier))))))