in reply to Regex vs. string

In simpler terms, changing your =~ to == will probably give you the results you were expecting.

What's happening is that you're currently asking whether the character on the right is anywhere inside the string on the left. That's why alpha ("1") and bravo ("2") are successful when the string is "12".