[OT] Programming language WATs

Bernard Helyer b.helyer at gmail.com
Fri Jan 20 20:16:58 PST 2012


On Friday, 20 January 2012 at 15:40:44 UTC, Robert Clipsham wrote:
> Just came across this amusing 4 minute video:
>
> https://www.destroyallsoftware.com/talks/wat
>
> Anyone have any other WATs you can do in other languages? Bonus 
> points for WATs you can do in D.

void main()
{
    import std.stdio;
    auto a = cast(int[]) [cast(ushort)1, cast(ushort) 2];
    writeln(a);
    auto b = [cast(ushort) 1, cast(ushort) 2];
    auto c = cast(int[]) b;
    writeln(c);
}




More information about the Digitalmars-d mailing list