make number of variables optional