Topological Sorting by murky-satyr

d='(%D)'m=d..io.read'*a':gsub('%s','%0%0')..'\n'while m do n=m:match'(%d+): *\n'm=n and(print(n)or m:gsub(d..n..d,'%1%2'))end

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return to the top page