比如传入[a b c d e], N=2, 要求返回数组[c d e a b]
二、in case you are not familiar with regular expression substitution, here's a quick tutorial:
the syntax of string substitution is:
VARIABLE =~ s/SEARCH_PATTERN/NEW_STRING/
For example,
$a = 'abc,123';
$a =~ s/(\w+),(\w+)/\2,\1/; # $a is now '123,abc' because \1='abc' and \2='123'
Here's the question:
write ONE substitution statement(ie. s/SEARCH_PATTERN/NEW_STRING/) so that
"<date>1999-02-25</date>" will be updated to "<date>02-25-1999</date>" AND
"<date>2005-11-03</date>" will be updated to "<date>11-03-2005</date>"