Solution 1 - The solution is ^(0[1-9]|1[012])$
Result - The above regular expression allows
01
02
03
04
05
06
07
08
09
10
11
12
Solution 2 - The solution is ^([1-9]|1[012])$
Result - The above regular expression allows
1
2
3
4
5
6
7
8
9
10
11
12
Solution 3 - This integrated solution 1 and solution 2 ^(0?[1-9]|1[012])$
Result - The above regular expression allows
1
2
3
4
5
6
7
8
9
10
11
12
01
02
03
04
05
06
07
08
09
10
11
12
No comments:
Post a Comment