Title |
Test
Find
Pattern Title
|
Expression |
^([6011]{4})([0-9]{12})$ |
Description |
Validate against any discover card number. All DC's start with 6011 and are followed by 12 other numbers. |
Matches |
6011212541254121 | 6011523654125685 |
Non-Matches |
5021152365212541 | 601126523652321 | 60112563212563215 |
Author |
Rating:
Not yet rated.
Jeff Johns
|
Source |
|
Your Rating |
|
Title: Beware: faulty RegEx!
Name: Andrew H
Date: 8/12/2010 5:24:38 AM
Comment:
This will also match numbers starting 6101, 1111, etc. because first statement is invalid.
Would be better as ^6011([0-9]{12})$