Back to labs/answer key page

grep '^[^xX]*[xX][^xX]*$' daphne.txt 

The key points in this excercise were the beginning and end of line characters (^ and $), the complement character (^ inside [...]), and the Kleene star (*).

(daphne.txt is in /home/corpora/english/gutenberg/etexts00.)

Back to labs/answer key page

-----

Emily M. Bender
Last modified: Fri Dec 8 12:03:48 2000