Take words.txt and regex.php and print out the words that match the following conditions:
<?php
// This solution puts all regular expressions into an array
// and selects one at a time.
$regexps = array(
"/Marty/", // 1. Both Martys
"/Stepp/", // 2. The Stepp Brothers
"/hw\d/", // 3. HW Directories
"/abba/", // 4. Babbage through scabbards
"/^(yes)$/i", // 5. Any variation of "yes"
"/^\w{7}$/", // 6. Words of length seven
"/bert$/" // 7. Characters from Dilbert
);
$regexp = $regexps[6];
?>