public static void main ( String [ ] args ) {
  Scanner scan = new Scanner ( System . in ) ;
  double N = scan . nextDouble ( ) ;
  double d = scan . nextDouble ( ) ;
  double x = scan . nextDouble ( ) ;
  BigDecimal ans = new BigDecimal ( "0.0" ) ;
  while ( N > 0.5 ) {
    BigDecimal adnum = BigDecimal . valueOf ( d + x * ( N - 0.5 ) ) ;
    ans = ans . add ( adnum ) ;
    d = ( N + 1.0 ) * d / N + ( 5.0 * x ) / ( 2.0 * N ) ;
    x = ( 1.0 + ( 2.0 / N ) ) * x ;
    -- N ;
  }
  DecimalFormat format = new DecimalFormat ( "#.#" ) ;
  format . setMinimumFractionDigits ( 20 ) ;
  System . out . println ( format . format ( ans ) ) ;
}

public static void main ( String [ ] args ) { Scanner scan = new Scanner ( System . in ) ; double N = scan . nextDouble ( ) ; double d = scan . nextDouble ( ) ; double x = scan . nextDouble ( ) ; BigDecimal ans = new BigDecimal ( "0.0" ) ; while ( N > 0.5 ) { BigDecimal adnum = BigDecimal . valueOf ( d + x * ( N - 0.5 ) ) ; ans = ans . add ( adnum ) ; d = ( N + 1.0 ) * d / N + ( 5.0 * x ) / ( 2.0 * N ) ; x = ( 1.0 + ( 2.0 / N ) ) * x ; -- N ; } DecimalFormat format = new DecimalFormat ( " # . # " ) ; format . setMinimumFractionDigits ( 20 ) ; System . out . println ( format . format ( ans ) ) ; }
(method_declaration (modifiers) type: (void_type) name: (identifier) parameters: (formal_parameters (formal_parameter type: (array_type element: (type_identifier) dimensions: (dimensions)) name: (identifier))) body: (block (local_variable_declaration type: (type_identifier) declarator: (variable_declarator name: (identifier) value: (object_creation_expression type: (type_identifier) arguments: (argument_list (field_access object: (identifier) field: (identifier)))))) (local_variable_declaration type: (floating_point_type) declarator: (variable_declarator name: (identifier) value: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))) (local_variable_declaration type: (floating_point_type) declarator: (variable_declarator name: (identifier) value: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))) (local_variable_declaration type: (floating_point_type) declarator: (variable_declarator name: (identifier) value: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))) (local_variable_declaration type: (type_identifier) declarator: (variable_declarator name: (identifier) value: (object_creation_expression type: (type_identifier) arguments: (argument_list (string_literal))))) (while_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (decimal_floating_point_literal))) body: (block (local_variable_declaration type: (type_identifier) declarator: (variable_declarator name: (identifier) value: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (binary_expression left: (identifier) right: (binary_expression left: (identifier) right: (parenthesized_expression (binary_expression left: (identifier) right: (decimal_floating_point_literal))))))))) (expression_statement (assignment_expression left: (identifier) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (binary_expression left: (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (decimal_floating_point_literal))) right: (identifier)) right: (identifier)) right: (binary_expression left: (parenthesized_expression (binary_expression left: (decimal_floating_point_literal) right: (identifier))) right: (parenthesized_expression (binary_expression left: (decimal_floating_point_literal) right: (identifier))))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (parenthesized_expression (binary_expression left: (decimal_floating_point_literal) right: (parenthesized_expression (binary_expression left: (decimal_floating_point_literal) right: (identifier))))) right: (identifier)))) (expression_statement (update_expression (identifier))))) (local_variable_declaration type: (type_identifier) declarator: (variable_declarator name: (identifier) value: (object_creation_expression type: (type_identifier) arguments: (argument_list (string_literal))))) (expression_statement (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (decimal_integer_literal)))) (expression_statement (method_invocation object: (field_access object: (identifier) field: (identifier)) name: (identifier) arguments: (argument_list (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (identifier))))))))