Ubuntu Pastebin

Paste from cmaloney at Thu, 12 Jan 2017 15:58:17 +0000

Download as text
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
import std.stdio, std.array, std.conv;
 
void main(string[] args)
{
    try
    {
        auto source = args.length > 1 ? File(args[1], "r") : stdin;
        auto text   = source.byLine.join.to!(string);
 
        writeln(text);
    }
    catch (Exception ex)
    {
        writeln(ex.msg);
    }
}
Download as text