regex1 = /[^a]*|[^a]*a[^b]*/
regex2 = /[^a]*|[^a]*a[^b]*|[^a]*a[^b]*b[^c]*/
puts regex1.match("AB")
puts regex1.match("ab")
puts regex2.match("ABC")
puts regex2.match("abc")
cmVnZXgxID0gL1teYV0qfFteYV0qYVteYl0qLwpyZWdleDIgPSAvW15hXSp8W15hXSphW15iXSp8W15hXSphW15iXSpiW15jXSovCgpwdXRzIHJlZ2V4MS5tYXRjaCgiQUIiKQpwdXRzIHJlZ2V4MS5tYXRjaCgiYWIiKQpwdXRzIHJlZ2V4Mi5tYXRjaCgiQUJDIikKcHV0cyByZWdleDIubWF0Y2goImFiYyIpCg==