in reply to pattern matching

A few tips:

This should get you started I hope, -gjb-