On 2/11/21 6:22 PM, H. S. Teoh wrote: > bool[size_t] hashes;
I would start with an even simpler solution until it's proven that there still is a memory issue:
import std.stdio; void main() { bool[string] lines; foreach (line; stdin.byLine) { if (line !in lines) { stdout.writeln(line); lines[line.idup] = true; } // else this line already seen before; just skip it } } (Grr... Thanks for the tab characters! :p) Ali