Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def l_spread (num_accents, size)
- (spread num_accents, size)
- .chunk_while { |i,j| !j }
- .map { |ary| ary.map { |a| if a then ary.length else 0 end } }
- .flatten
- .map { |i| [ i != 0, i ] }
- .ring
- end
Add Comment
Please, Sign In to add comment