Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8535447
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T10:26:00+00:00 2026-06-11T10:26:00+00:00

Alright, so while the pattern [abc] matches a single character that is a ,

  • 0

Alright, so while the pattern [abc] matches a single character that is a, b, or c, the pattern [^abc] matches any given character that isn’t a, b, or c.

Now if I substitue string for character in the above statement, it would still apply if I also changed the first pattern to an alternation construct like (abc|def|ghi). — it would match a consecutive string of three characters equal to abc, def, or ghi. What can I do to match any string of three characters that isn’t equal to abc, def, or ghi?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T10:26:01+00:00Added an answer on June 11, 2026 at 10:26 am

    This is a common question with regexes, and the short answer is “no”, the way regular expressions operate doesn’t provide a way of saying “any 3-letter string except …”.

    However, some regular expression engines allow for what are called “negative look-ahead assertions”. These are a little tricky to get your head around – this explanation of lookaround seems to cover it quite well, if a little technically.

    The important thing about lookahead is that it is “zero-width” – it doesn’t “use up” any of the string. So in Javascript you can match a string like this: 'abc123ghi'.match(/abc(?!def)...ghi/) – the (?!def) says that there mustn’t be the letters 'def' after the 'abc', but the ... needs to be there to say that there should be some other 3 characters there instead.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Alright so I've been making an attempt at this for a while now. My
Alright, this has been on my mind for a while now. I'm in the
Alright so i need to open a .txt file that will be created in
Alright, so I have been wondering how to do this for a while. Basically,
Alright, currently I'm using GD to create a PNG image that logs a few
Alright so this is a bizarre cross platform thing that I'm experiencing with text
Alright, nub question. I know. Basic response might be Convert.ToInt32(string); But naturally, C# does
Alright so we had a problem recently In reporting services some of the String
Alright so I'm just trying to open a basic window with GLFW, and while
Alright, I'm trying to make it so that someone can vote for a server

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.