D For A Web Developer

Meta via Digitalmars-d digitalmars-d at puremagic.com
Sun May 4 07:01:23 PDT 2014


On Sunday, 4 May 2014 at 10:04:12 UTC, bearophile wrote:
> Danny Weldon:
>
>> If somebody has some time, they could post a solution in D to 
>> this problem:
>>
>> http://codegolf.stackexchange.com/questions/26323/how-slow-is-python-really-or-how-fast-is-your-language
>>
>> It all helps to get the language visible.
>
> Here are my solutions:
> http://forum.dlang.org/thread/pvojsrqmaksqwokuekhk@forum.dlang.org
>
> I don't have a Stackexchange account. You are welcome to post 
> the two solutions (of two different problems).
>
> Bye,
> bearophile

I'm not able to run either version on DPaste. It fails to compile 
on both examples with no error message. Both example compile fine 
locally with DMD 2.065, however.

Your C++ translation: ~277ms
Your second version:  ~2.34ms/round

I just compiled and ran each binary a few times, so these might 
not be good measurements. I compiled both versions without 
-inline, as they ran slower with it enabled. LDC might do a 
better job with this.


More information about the Digitalmars-d mailing list