I don't know. The idea was about something mutable with constant width. And you need to swap items in it making as less as possible number of it (swaps)Maybe it's not best idea for Kata =)
On Fri, Mar 12, 2010 at 4:39 PM, David Pollak <feeder.of...@gmail.com> wrote:
Can I suggest using a List or a Seq rather than an array. The overhead in 2.8 related to Arrays distract from the intent of the Kata.On Fri, Mar 12, 2010 at 12:29 AM, Aleksandr Motsjonov <sos...@gmail.com> wrote:
Write a method, whose arguments are array and number (n), which returns same array, but where first n elements are in the end.For ex:[1,2,3,4,5,6,7] n = 3must returns:[4,5,6,7,1,2,3]
And there is one rule: you can use only one array (given as arguments)Alex.
--
Lift, the simply functional web framework http://liftweb.net
Beginning Scala http://www.apress.com/book/view/1430219890
Follow me: http://twitter.com/dpp
Surf the harmonics