Last-to-first mapping

Sign in to test your solution.