public static void main ( String [ ] args ) {
  Scanner sc = new Scanner ( System . in ) ;
  PrintWriter pw = new PrintWriter ( System . out ) ;
  int N = sc . nextInt ( ) ;
  int D = sc . nextInt ( ) ;
  int [ ] x = new int [ N ] ;
  for ( int i = 0 ;
  i < N ;
  i ++ ) x [ i ] = sc . nextInt ( ) ;
  int Q = sc . nextInt ( ) ;
  long [ ] qq = new long [ Q ] ;
  for ( int i = 0 ;
  i < Q ;
  i ++ ) qq [ i ] = ( sc . nextLong ( ) - 1 ) << 30 | i ;
  Arrays . sort ( qq ) ;
  int [ ] rest = new int [ N + 1 ] ;
  rest [ 0 ] = D ;
  for ( int i = 0 ;
  i < N ;
  i ++ ) rest [ i + 1 ] = Math . min ( rest [ i ] , Math . abs ( rest [ i ] - x [ i ] ) ) ;
  boolean [ ] ans = new boolean [ Q ] ;
  long range = 0 ;
  int idx = Q - 1 ;
  for ( int i = N - 1 ;
  i >= 0 ;
  i -- ) {
    while ( idx >= 0 && ( qq [ idx ] >> 30 ) == i ) {
      if ( rest [ i ] > range ) {
        ans [ ( int ) ( qq [ idx ] & ( ( 1 << 30 ) - 1 ) ) ] = true ;
      }
      idx -- ;
    }
    if ( x [ i ] <= range * 2 + 1 ) {
      range += x [ i ] ;
    }
  }
  for ( int i = 0 ;
  i < Q ;
  i ++ ) pw . println ( ans [ i ] ? "YES" : "NO" ) ;
  sc . close ( ) ;
  pw . close ( ) ;
}

public static void main ( String [ ] args ) { Scanner sc = new Scanner ( System . in ) ; PrintWriter pw = new PrintWriter ( System . out ) ; int N = sc . nextInt ( ) ; int D = sc . nextInt ( ) ; int [ ] x = new int [ N ] ; for ( int i = 0 ; i < N ; i ++ ) x [ i ] = sc . nextInt ( ) ; int Q = sc . nextInt ( ) ; long [ ] qq = new long [ Q ] ; for ( int i = 0 ; i < Q ; i ++ ) qq [ i ] = ( sc . nextLong ( ) - 1 ) << 30 | i ; Arrays . sort ( qq ) ; int [ ] rest = new int [ N + 1 ] ; rest [ 0 ] = D ; for ( int i = 0 ; i < N ; i ++ ) rest [ i + 1 ] = Math . min ( rest [ i ] , Math . abs ( rest [ i ] - x [ i ] ) ) ; boolean [ ] ans = new boolean [ Q ] ; long range = 0 ; int idx = Q - 1 ; for ( int i = N - 1 ; i >= 0 ; i -- ) { while ( idx >= 0 && ( qq [ idx ] >> 30 ) == i ) { if ( rest [ i ] > range ) { ans [ ( int ) ( qq [ idx ] & ( ( 1 << 30 ) - 1 ) ) ] = true ; } idx -- ; } if ( x [ i ] <= range * 2 + 1 ) { range += x [ i ] ; } } for ( int i = 0 ; i < Q ; i ++ ) pw . println ( ans [ i ] ? " YES " : " NO " ) ; sc . close ( ) ; pw . 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: (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) value: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))) (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 (identifier))))) (for_statement init: (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) condition: (binary_expression left: (identifier) right: (identifier)) update: (update_expression (identifier)) body: (expression_statement (assignment_expression left: (array_access array: (identifier) index: (identifier)) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list))))) (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))) (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 (identifier))))) (for_statement init: (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) condition: (binary_expression left: (identifier) right: (identifier)) update: (update_expression (identifier)) body: (expression_statement (assignment_expression left: (array_access array: (identifier) index: (identifier)) right: (binary_expression left: (binary_expression left: (parenthesized_expression (binary_expression left: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)) right: (decimal_integer_literal))) right: (decimal_integer_literal)) right: (identifier))))) (expression_statement (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (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 (binary_expression left: (identifier) right: (decimal_integer_literal)))))) (expression_statement (assignment_expression left: (array_access array: (identifier) index: (decimal_integer_literal)) right: (identifier))) (for_statement init: (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) condition: (binary_expression left: (identifier) right: (identifier)) update: (update_expression (identifier)) body: (expression_statement (assignment_expression left: (array_access array: (identifier) index: (binary_expression left: (identifier) right: (decimal_integer_literal))) right: (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (array_access array: (identifier) index: (identifier)) (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (binary_expression left: (array_access array: (identifier) index: (identifier)) right: (array_access array: (identifier) index: (identifier)))))))))) (local_variable_declaration type: (array_type element: (boolean_type) dimensions: (dimensions)) declarator: (variable_declarator name: (identifier) value: (array_creation_expression type: (boolean_type) dimensions: (dimensions_expr (identifier))))) (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: (binary_expression left: (identifier) right: (decimal_integer_literal)))) (for_statement init: (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (binary_expression left: (identifier) right: (decimal_integer_literal)))) condition: (binary_expression left: (identifier) right: (decimal_integer_literal)) update: (update_expression (identifier)) body: (block (while_statement condition: (parenthesized_expression (binary_expression left: (binary_expression left: (identifier) right: (decimal_integer_literal)) right: (binary_expression left: (parenthesized_expression (binary_expression left: (array_access array: (identifier) index: (identifier)) right: (decimal_integer_literal))) right: (identifier)))) body: (block (if_statement condition: (parenthesized_expression (binary_expression left: (array_access array: (identifier) index: (identifier)) right: (identifier))) consequence: (block (expression_statement (assignment_expression left: (array_access array: (identifier) index: (cast_expression type: (integral_type) value: (parenthesized_expression (binary_expression left: (array_access array: (identifier) index: (identifier)) right: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (decimal_integer_literal) right: (decimal_integer_literal))) right: (decimal_integer_literal))))))) right: (true))))) (expression_statement (update_expression (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (array_access array: (identifier) index: (identifier)) right: (binary_expression left: (binary_expression left: (identifier) right: (decimal_integer_literal)) right: (decimal_integer_literal)))) consequence: (block (expression_statement (assignment_expression left: (identifier) right: (array_access array: (identifier) index: (identifier)))))))) (for_statement init: (local_variable_declaration type: (integral_type) declarator: (variable_declarator name: (identifier) value: (decimal_integer_literal))) condition: (binary_expression left: (identifier) right: (identifier)) update: (update_expression (identifier)) body: (expression_statement (method_invocation object: (identifier) name: (identifier) arguments: (argument_list (ternary_expression condition: (array_access array: (identifier) index: (identifier)) consequence: (string_literal) alternative: (string_literal)))))) (expression_statement (method_invocation object: (identifier) name: (identifier) arguments: (argument_list))) (expression_statement (method_invocation object: (identifier) name: (identifier) arguments: (argument_list)))))