worked through integers and pattern matching