Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Let's Code in D

Name: Anonymous 2012-02-02 9:08

Hey /prog/, why aren't you writing D, God's gift to programmers? Let's get this ball rolling.

import std.stdio;

template factorial(int n)
{
    const factorial = n * factorial!(n-1);
}

template factorial(int n : 1)
{
    const factorial = 1;
}

void main(string[] argv)
{
   writeln(factorial!(10));
}

Name: Anonymous 2012-02-02 16:31

Frst of all, templates are disgusting; get some real data structures. Second of all Haskell is fast. Not C fast but god damn it laughs at Erlang and Java and other higher-level languages, not to mention pieces of shit like Python and Ruby. God damn.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List