public static void find ( String [ ] str1 , int n ) {
  int i = 0 ;
  int j = 0 ;
  int count = 0 ;
  while ( i < n ) {
    for ( j = 0 ;
    j < str1 [ i ] . length ( ) ;
    j ++ ) {
      if ( str1 [ i ] . substring ( j , j + 1 ) . equals ( "r" ) ) {
        count = count + 1 ;
        break ;
      }
    }
    i ++ ;
  }
  System . out . println ( count ) ;
}

public static void find ( String [ ] str1 , int n ) { int i = 0 ; int j = 0 ; int count = 0 ; while ( i < n ) { for ( j = 0 ; j < str1 [ i ] . length ( ) ; j ++ ) { if ( str1 [ i ] . substring ( j , j + 1 ) . equals ( " r " ) ) { count = count + 1 ; break ; } } i ++ ; } System . out . println ( count ) ; }
(method_declaration (modifiers) type: (void_type) name: (identifier) parameters: (formal_parameters (formal_parameter type: (array_type element: (type_identifier) dimensions: (dimensions)) name: (identifier)) (formal_parameter type: (integral_type) name: (identifier))) body: (block (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) (while_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) body: (block (for_statement init: (assignment_expression left: (identifier) right: (decimal_integer_literal)) condition: (binary_expression left: (identifier) right: (method_invocation object: (array_access array: (identifier) index: (identifier)) name: (identifier) arguments: (argument_list))) update: (update_expression (identifier)) body: (block (if_statement condition: (parenthesized_expression (method_invocation object: (method_invocation object: (array_access array: (identifier) index: (identifier)) name: (identifier) arguments: (argument_list (identifier) (binary_expression left: (identifier) right: (decimal_integer_literal)))) name: (identifier) arguments: (argument_list (string_literal)))) consequence: (block (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (decimal_integer_literal)))) (break_statement))))) (expression_statement (update_expression (identifier))))) (expression_statement (method_invocation object: (field_access object: (identifier) field: (identifier)) name: (identifier) arguments: (argument_list (identifier))))))