static boolean isSubArray ( int A [ ] , int B [ ] , int n , int m ) {
  int i = 0 , j = 0 ;
  while ( i < n && j < m ) {
    if ( A [ i ] == B [ j ] ) {
      i ++ ;
      j ++ ;
      if ( j == m ) return true ;
    }
    else {
      i = i - j + 1 ;
      j = 0 ;
    }
  }
  return false ;
}

static boolean isSubArray ( int A [ ] , int B [ ] , int n , int m ) { int i = 0 , j = 0 ; while ( i < n && j < m ) { if ( A [ i ] == B [ j ] ) { i ++ ; j ++ ; if ( j == m ) return true ; } else { i = i - j + 1 ; j = 0 ; } } return false ; }
(method_declaration (modifiers) type: (boolean_type) name: (identifier) parameters: (formal_parameters (formal_parameter type: (integral_type) name: (identifier) dimensions: (dimensions)) (formal_parameter type: (integral_type) name: (identifier) dimensions: (dimensions)) (formal_parameter type: (integral_type) 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)) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) (while_statement condition: (parenthesized_expression (binary_expression left: (binary_expression left: (identifier) right: (identifier)) right: (binary_expression left: (identifier) right: (identifier)))) body: (block (if_statement condition: (parenthesized_expression (binary_expression left: (array_access array: (identifier) index: (identifier)) right: (array_access array: (identifier) index: (identifier)))) consequence: (block (expression_statement (update_expression (identifier))) (expression_statement (update_expression (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) consequence: (return_statement (true)))) alternative: (block (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (binary_expression left: (identifier) right: (identifier)) right: (decimal_integer_literal)))) (expression_statement (assignment_expression left: (identifier) right: (decimal_integer_literal))))))) (return_statement (false))))