public static void main ( String [ ] args ) {
  Scanner scan = new Scanner ( System . in ) ;
  int i , temp , temp1 , n ;
  String text , str ;
  char [ ] ch = new char [ 100 ] ;
  text = scan . nextLine ( ) ;
  ch = text . toCharArray ( ) ;
  for ( i = 0 ;
  i < text . length ( ) ;
  ++ i ) {
    temp = ( int ) ch [ i ] ;
    str = Integer . toBinaryString ( temp ) ;
    while ( str . length ( ) < 8 ) str = "0" + str ;
    n = str . length ( ) ;
    str = reverse ( str ) ;
    temp = Integer . parseInt ( str . substring ( 0 , n ) , 2 ) ;
    if ( i == 0 ) temp1 = 0 ;
    else {
      temp1 = ( int ) ch [ i - 1 ] ;
      str = Integer . toBinaryString ( temp1 ) ;
      while ( str . length ( ) < 8 ) str = "0" + str ;
      n = str . length ( ) ;
      str = reverse ( str ) ;
      temp1 = Integer . parseInt ( str . substring ( 0 , n ) , 2 ) ;
    }
    temp = temp1 - temp ;
    if ( temp < 0 ) {
      temp *= ( - 1 ) ;
      temp = 256 - ( temp % 256 ) ;
    }
    else temp = temp % 256 ;
    System . out . println ( temp ) ;
  }
}

public static void main ( String [ ] args ) { Scanner scan = new Scanner ( System . in ) ; int i , temp , temp1 , n ; String text , str ; char [ ] ch = new char [ 100 ] ; text = scan . nextLine ( ) ; ch = text . toCharArray ( ) ; for ( i = 0 ; i < text . length ( ) ; ++ i ) { temp = ( int ) ch [ i ] ; str = Integer . toBinaryString ( temp ) ; while ( str . length ( ) < 8 ) str = "0" + str ; n = str . length ( ) ; str = reverse ( str ) ; temp = Integer . parseInt ( str . substring ( 0 , n ) , 2 ) ; if ( i == 0 ) temp1 = 0 ; else { temp1 = ( int ) ch [ i - 1 ] ; str = Integer . toBinaryString ( temp1 ) ; while ( str . length ( ) < 8 ) str = "0" + str ; n = str . length ( ) ; str = reverse ( str ) ; temp1 = Integer . parseInt ( str . substring ( 0 , n ) , 2 ) ; } temp = temp1 - temp ; if ( temp < 0 ) { temp *= ( - 1 ) ; temp = 256 - ( temp % 256 ) ; } else temp = temp % 256 ; System . out . println ( temp ) ; } }
(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: (integral_type) declarator: (variable_declarator name: (identifier)) declarator: (variable_declarator name: (identifier)) declarator: (variable_declarator name: (identifier)) declarator: (variable_declarator name: (identifier))) (local_variable_declaration type: (type_identifier) declarator: (variable_declarator name: (identifier)) declarator: (variable_declarator name: (identifier))) (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 (decimal_integer_literal))))) (expression_statement (assignment_expression left: (identifier) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))) (expression_statement (assignment_expression left: (identifier) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))) (for_statement init: (assignment_expression left: (identifier) right: (decimal_integer_literal)) condition: (binary_expression left: (identifier) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list))) update: (update_expression (identifier)) body: (block (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (integral_type) value: (array_access array: (identifier) index: (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (identifier))))) (while_statement condition: (parenthesized_expression (binary_expression left: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)) right: (decimal_integer_literal))) body: (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (string_literal) right: (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))) (expression_statement (assignment_expression left: (identifier) right: (method_invocation name: (identifier) arguments: (argument_list (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (decimal_integer_literal) (identifier))) (decimal_integer_literal))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (decimal_integer_literal))) consequence: (expression_statement (assignment_expression left: (identifier) right: (decimal_integer_literal))) alternative: (block (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (integral_type) value: (array_access array: (identifier) index: (binary_expression left: (identifier) right: (decimal_integer_literal)))))) (expression_statement (assignment_expression left: (identifier) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (identifier))))) (while_statement condition: (parenthesized_expression (binary_expression left: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)) right: (decimal_integer_literal))) body: (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (string_literal) right: (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))) (expression_statement (assignment_expression left: (identifier) right: (method_invocation name: (identifier) arguments: (argument_list (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (decimal_integer_literal) (identifier))) (decimal_integer_literal))))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (identifier)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (decimal_integer_literal))) consequence: (block (expression_statement (assignment_expression left: (identifier) right: (parenthesized_expression (unary_expression operand: (decimal_integer_literal))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (decimal_integer_literal) right: (parenthesized_expression (binary_expression left: (identifier) right: (decimal_integer_literal))))))) alternative: (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (decimal_integer_literal))))) (expression_statement (method_invocation object: (field_access object: (identifier) field: (identifier)) name: (identifier) arguments: (argument_list (identifier))))))))