Exercise : Regular Expressions (by Zack Cava)
Write a regular expression () that would match the following kinds of patterns.
You can use the site to test your regex.
-
students' letter grades such as A, B+, or D-
()
()
-
DNA (strings of A, C, G, or T) in upper/lower case
()
()
-
a US ZIP code
()
()
-
a credit card number, with optional dashes every 4 numbers
()
()
-
a real number such as 3.14 or -42.8775
()
()
-
dollar amounts of at least $100.00
()
()
-
words that contain at least two vowels (A, E, I, O, or U)
()
()