I'm having a bit of a regex mental blank. I know it could be done manually ie (aaaa|bbbb|cccc...), but is there an easier way to check whether an alphanumeric character appears 4 or more times in a row in a string?
[a-z0-9]{4,}
Guess I didn't explain too well, I actually want to match any strings that contain 4 of the same char in a row - aaaa or bbbb, not abcd.
([a-z0-9])\1\1\1
Thanks 🙂