Update writer.pl

shorter syntax for gathering function params and defining multiple vars