uses new pass-by-value constructor on line 41