N
N
newaitix2018-03-17 13:15:02
JavaScript
newaitix, 2018-03-17 13:15:02

Regular expression. Anything but 1, a,?

The string can start with any character except "1, a and ?"
The line start character is understandable "^". But how to put a negative? At what and groups of characters az and for a certain set of characters "hello".
I'll give you an example.
I want to say a line that does not start with 1 and then something follows, for example the word "hello"
1hello
6hello
*hello
7hello
dhello
In general, I need exactly negation and not enumeration of other options.
I'm asking for general development and not for assignment.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
V
Viktor Volkov, 2018-03-17
@VGVolkov

/^[^1a?].*\b/

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question