fork(10) download
  1. f=->(s){s.chars.chunk{|c|c.to_i.to_s==c}.select{|e|e[0]}.transpose[1]}
  2.  
  3. p f.call("z526ks4f.;8]\p")
Success #stdin #stdout 0.02s 7464KB
stdin
Standard input is empty
stdout
[["5", "2", "6"], ["4"], ["8"]]