The reverse() function returns a list in reversed order @foo = ( "a", "b", "c", "d" ); @foo = reverse( @foo ); # @foo is now ( "d", "c", "b", "a" )