Skip to content

Instantly share code, notes, and snippets.

@rsiddle
Created November 30, 2017 21:18
Show Gist options
  • Save rsiddle/3e839ee086a7d461f1889cffc34a2c70 to your computer and use it in GitHub Desktop.
Save rsiddle/3e839ee086a7d461f1889cffc34a2c70 to your computer and use it in GitHub Desktop.
Error in split_file.cr:34: no overload matches 'Array(String)#each_slice' with type (Int32 | String)
Overloads are:
- Enumerable(T)#each_slice(count : Int, reuse = false, &block)
- Iterable(T)#each_slice(count : Int, reuse = false)
data = File.read(input).split(/[\r\n]+/)
data.each_slice(lines) do |a|
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment