Use std.range.cycle with std.container.Array (slice the array to get a range).

http://dlang.org/phobos/std_range.html#.cycle

Reply via email to