Advertisement
Guest User

Untitled

a guest
Oct 25th, 2016
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.49 KB | None | 0 0
  1. # Regex Cheatsheet
  2.  
  3. Quick reference about regex to look up
  4.  
  5. ## Feature: Negative lookahead `?!`
  6.  
  7. Specifies a group that can not match after the main expression (if it matches, the result is discarded).
  8. Doesn't work in Javascript, but works on Sublime Text.
  9.  
  10. #### Situation: We have a list with the text `"user" : "<id>"` where the id vary betwen 123, 234, 345. You want to find if there is any other values for `<id>` that are not included in the list (123, 234, 345).
  11.  
  12. Regex: `user" : "(?!123|234|345)`
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement