private static boolean same ( List < Integer > list ) {
  for ( int i = 0 ;
  i < list . size ( ) - 1 ;
  i ++ ) {
    int a = list . get ( i ) ;
    int b = list . get ( i + 1 ) ;
    if ( a != b ) {
      return false ;
    }
  }
  return true ;
}

private static boolean same ( List < Integer > list ) { for ( int i = 0 ; i < list . size ( ) - 1 ; i ++ ) { int a = list . get ( i ) ; int b = list . get ( i + 1 ) ; if ( a != b ) { return false ; } } return true ; }
(method_declaration (modifiers) type: (boolean_type) name: (identifier) parameters: (formal_parameters (formal_parameter type: (generic_type (type_identifier) (type_arguments (type_identifier))) name: (identifier))) body: (block (for_statement init: (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) condition: (binary_expression left: (identifier) right: (binary_expression left: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)) right: (decimal_integer_literal))) update: (update_expression (identifier)) body: (block (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (identifier))))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (binary_expression left: (identifier) right: (decimal_integer_literal)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) consequence: (block (return_statement (false)))))) (return_statement (true))))