Write a subroutine, 'subst', which gets a string argument, $s. It should search $s and replace any occurrences of "$1" with the current value of $1, any occurrences of "$2" with the current value of $2, and so on. For example, if $1, $2, and $3 happen to be "dogs", "fish" and "carrots", then subst("$2, $1 and $3") should return "fish, dogs, and carrots" ---------------------------------------------------------------- Some notes: * I'll post an example solution here on Monday. * perl-qotw will only carry the quizzes and solutions. Discussion, remarks, comments, and soforth should go to perl-qotw-discuss@plover.com. To subscribe to that list, send mail to perl-qotw-discuss-subscribe@plover.com. * I'd like to request that nobody post any sample solutions or other spoilers to the discussion list until at least Saturday. * Even after Saturday, any solutions or other spoilers should always be marked with the word SPOILER in the subject line, so that other people won't see them by accident. * If you'd like to contribute a quiz question, send it to me. * I will set up a web archive eventually. In the meantime, old messages are always available by email. Send a message to perl-qotd-help@plover.com (or to perl-qotd-discussion-help@plover.com) for instructions. Thanks.