1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
|
{0, "(.*)*\\1", "xx"},
{0, "^", ""},
{0, "$", ""},
{0, "^$", ""},
{0, "^a$", "a"},
{0, "abc", "abc"},
{1, "abc", "xbc"},
{1, "abc", "axc"},
{1, "abc", "abx"},
{0, "abc", "xabcy"},
{0, "abc", "ababc"},
{0, "ab*c", "abc"},
{0, "ab*bc", "abc"},
{0, "ab*bc", "abbc"},
{0, "ab*bc", "abbbbc"},
{0, "ab+bc", "abbc"},
{1, "ab+bc", "abc"},
{1, "ab+bc", "abq"},
{0, "ab+bc", "abbbbc"},
{0, "ab?bc", "abbc"},
{0, "ab?bc", "abc"},
{1, "ab?bc", "abbbbc"},
{0, "ab?c", "abc"},
{0, "^abc$", "abc"},
{1, "^abc$", "abcc"},
{0, "^abc", "abcc"},
{1, "^abc$", "aabc"},
{0, "abc$", "aabc"},
{0, "^", "abc"},
{0, "$", "abc"},
{0, "a.c", "abc"},
{0, "a.c", "axc"},
{0, "a.*c", "axyzc"},
{1, "a.*c", "axyzd"},
{1, "a[bc]d", "abc"},
{0, "a[bc]d", "abd"},
{1, "a[b-d]e", "abd"},
{0, "a[b-d]e", "ace"},
{0, "a[b-d]", "aac"},
{0, "a[-b]", "a-"},
{0, "a[b-]", "a-"},
{1, "a[b-a]", "-"},
{2, "a[]b", "-"},
{2, "a[", "-"},
{0, "a]", "a]"},
{0, "a[]]b", "a]b"},
{0, "a[^bc]d", "aed"},
{1, "a[^bc]d", "abd"},
{0, "a[^-b]c", "adc"},
{1, "a[^-b]c", "a-c"},
{1, "a[^]b]c", "a]c"},
{0, "a[^]b]c", "adc"},
{0, "ab|cd", "abc"},
{0, "ab|cd", "abcd"},
{0, "()ef", "def"},
{0, "()*", "-"},
{1, "*a", "-"},
{0, "^*", "-"},
{0, "$*", "-"},
{1, "(*)b", "-"},
{1, "$b", "b"},
{2, "a\\", "-"},
{0, "a\\(b", "a(b"},
{0, "a\\(*b", "ab"},
{0, "a\\(*b", "a((b"},
{1, "a\\x", "a\\x"},
{1, "abc)", "-"},
{2, "(abc", "-"},
{0, "((a))", "abc"},
{0, "(a)b(c)", "abc"},
{0, "a+b+c", "aabbabc"},
{0, "a**", "-"},
{0, "a*?", "-"},
{0, "(a*)*", "-"},
{0, "(a*)+", "-"},
{0, "(a|)*", "-"},
{0, "(a*|b)*", "-"},
{0, "(a+|b)*", "ab"},
{0, "(a+|b)+", "ab"},
{0, "(a+|b)?", "ab"},
{0, "[^ab]*", "cde"},
{0, "(^)*", "-"},
{0, "(ab|)*", "-"},
{2, ")(", "-"},
{1, "abc", ""},
{1, "abc", ""},
{0, "a*", ""},
{0, "([abc])*d", "abbbcd"},
{0, "([abc])*bcd", "abcd"},
{0, "a|b|c|d|e", "e"},
{0, "(a|b|c|d|e)f", "ef"},
{0, "((a*|b))*", "-"},
{0, "abcd*efg", "abcdefg"},
{0, "ab*", "xabyabbbz"},
{0, "ab*", "xayabbbz"},
{0, "(ab|cd)e", "abcde"},
{0, "[abhgefdc]ij", "hij"},
{1, "^(ab|cd)e", "abcde"},
{0, "(abc|)ef", "abcdef"},
{0, "(a|b)c*d", "abcd"},
{0, "(ab|ab*)bc", "abc"},
{0, "a([bc]*)c*", "abc"},
{0, "a([bc]*)(c*d)", "abcd"},
{0, "a([bc]+)(c*d)", "abcd"},
{0, "a([bc]*)(c+d)", "abcd"},
{0, "a[bcd]*dcdcde", "adcdcde"},
{1, "a[bcd]+dcdcde", "adcdcde"},
{0, "(ab|a)b*c", "abc"},
{0, "((a)(b)c)(d)", "abcd"},
{0, "[A-Za-z_][A-Za-z0-9_]*", "alpha"},
{0, "^a(bc+|b[eh])g|.h$", "abh"},
{0, "(bc+d$|ef*g.|h?i(j|k))", "effgz"},
{0, "(bc+d$|ef*g.|h?i(j|k))", "ij"},
{1, "(bc+d$|ef*g.|h?i(j|k))", "effg"},
{1, "(bc+d$|ef*g.|h?i(j|k))", "bcdd"},
{0, "(bc+d$|ef*g.|h?i(j|k))", "reffgz"},
{1, "((((((((((a))))))))))", "-"},
{0, "(((((((((a)))))))))", "a"},
{1, "multiple words of text", "uh-uh"},
{0, "multiple words", "multiple words, yeah"},
{0, "(.*)c(.*)", "abcde"},
{1, "\\((.*),", "(.*)\\)"},
{1, "[k]", "ab"},
{0, "abcd", "abcd"},
{0, "a(bc)d", "abcd"},
{0, "a[-]?c", "ac"},
{0, "(....).*\\1", "beriberi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Muammar Qaddafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Mo'ammar Gadhafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Muammar Kaddafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Muammar Qadhafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Moammar El Kadhafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Muammar Gadafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Mu'ammar al-Qadafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Moamer El Kazzafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Moamar al-Gaddafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Mu'ammar Al Qathafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Muammar Al Qathafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Mo'ammar el-Gadhafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Moamar El Kadhafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Muammar al-Qadhafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Mu'ammar al-Qadhdhafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Mu'ammar Qadafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Moamar Gaddafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Mu'ammar Qadhdhafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Muammar Khaddafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Muammar al-Khaddafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Mu'amar al-Kadafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Muammar Ghaddafy"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Muammar Ghadafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Muammar Ghaddafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Muamar Kaddafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Muammar Quathafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Muammar Gheddafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Muamar Al-Kaddafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Moammar Khadafy "},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Moammar Qudhafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Mu'ammar al-Qaddafi"},
{0, "M[ou]'?am+[ae]r .*([AEae]l[- ])?[GKQ]h?[aeu]+([dtz][dhz]?)+af[iy]", "Mulazim Awwal Mu'ammar Muhammad Abu Minyar al-Qadhafi"},
|