public static void main ( String [ ] args ) {
  Scanner sc = new Scanner ( System . in ) ;
  char [ ] c = sc . next ( ) . toCharArray ( ) ;
  int x = 0 , y = 0 ;
  for ( char ch : c ) {
    if ( ch == 'x' ) x ++ ;
    else y ++ ;
  }
  StringBuilder ans = new StringBuilder ( ) ;
  int left ;
  left = Math . abs ( x - y ) ;
  char ansChar = x > y ? 'x' : 'y' ;
  while ( left -- > 0 ) ans . append ( ansChar ) ;
  System . out . println ( ans . toString ( ) ) ;
  sc . close ( ) ;
}

public static void main ( String [ ] args ) { Scanner sc = new Scanner ( System . in ) ; char [ ] c = sc . next ( ) . toCharArray ( ) ; int x = 0 , y = 0 ; for ( char ch : c ) { if ( ch == ' x ' ) x ++ ; else y ++ ; } StringBuilder ans = new StringBuilder ( ) ; int left ; left = Math . abs ( x - y ) ; char ansChar = x > y ? ' x ' : ' y ' ; while ( left -- > 0 ) ans . append ( ansChar ) ; System . out . println ( ans . toString ( ) ) ; sc . close ( ) ; }
(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: (array_type element: (integral_type) dimensions: (dimensions)) declarator: (variable_declarator name: (identifier) value: (method_invocation object: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)) name: (identifier) arguments: (argument_list)))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal)) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) (enhanced_for_statement type: (integral_type) name: (identifier) value: (identifier) body: (block (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (character_literal))) consequence: (expression_statement (update_expression (identifier))) alternative: (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)))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (binary_expression left: (identifier) right: (identifier)))))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (ternary_expression condition: (binary_expression left: (identifier) right: (identifier)) consequence: (character_literal) alternative: (character_literal)))) (while_statement condition: (parenthesized_expression (binary_expression left: (update_expression (identifier)) right: (decimal_integer_literal))) body: (expression_statement (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (identifier))))) (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))))) (expression_statement (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))))