PatternMatchExample modified