www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - Idiomatic snippets

reply "Val" <admin programming-idioms.org> writes:
Hello Developers
I set up a website about how one would perform common programming 
tasks in the most idiomatic form in different languages. It is 
intended to be didactic, it's open to contributions (like a wiki) 
and we'd love to have more snippets written in D.
It would hugely help if a few of you picked a random idiom 
statement :
   http://www.programming-idioms.org/random-idiom
and clicked [(+) New implementation...] to write a D 
implementation. Most often, 2 lines suffice.

As you can see in the language coverage page: 
http://www.programming-idioms.org/about#about-block-language-coverage , we
don't have many D impl yet (click >> to reveal more than the 12 first langs).
You're also very welcome to add new idioms, as long as it's not 
D-specific, not tied to a library, and not a complex algorithm.
UI works fine but is not perfect yet, so any feedback is also 
welcome.

Cheers
  Val
Aug 20 2015
next sibling parent "BBasile" <bb.temp gmx.com> writes:
On Thursday, 20 August 2015 at 13:28:00 UTC, Val wrote:
 Hello Developers
 I set up a website about how one would perform common 
 programming tasks in the most idiomatic form in different 
 languages. It is intended to be didactic, it's open to 
 contributions (like a wiki) and we'd love to have more snippets 
 written in D.
 It would hugely help if a few of you picked a random idiom 
 statement :
   http://www.programming-idioms.org/random-idiom
 and clicked [(+) New implementation...] to write a D 
 implementation. Most often, 2 lines suffice.

 As you can see in the language coverage page: 
 http://www.programming-idioms.org/about#about-block-language-coverage , we
don't have many D impl yet (click >> to reveal more than the 12 first langs).
 You're also very welcome to add new idioms, as long as it's not 
 D-specific, not tied to a library, and not a complex algorithm.
 UI works fine but is not perfect yet, so any feedback is also 
 welcome.

 Cheers
  Val
Nice site, possibly successful, despite of being closed to Rosetta Code. The ability to edit without registration is a plus. Already added a few D stuffs. What about a dice for the "go to random idiom" ? Also put in front of every page...
Aug 20 2015
prev sibling next sibling parent reply Steven Schveighoffer <schveiguy yahoo.com> writes:
On 8/20/15 9:27 AM, Val wrote:
 Hello Developers
 I set up a website about how one would perform common programming tasks
 in the most idiomatic form in different languages. It is intended to be
 didactic, it's open to contributions (like a wiki) and we'd love to have
 more snippets written in D.
 It would hugely help if a few of you picked a random idiom statement :
    http://www.programming-idioms.org/random-idiom
 and clicked [(+) New implementation...] to write a D implementation.
 Most often, 2 lines suffice.

 As you can see in the language coverage page:
 http://www.programming-idioms.org/about#about-block-language-coverage ,
 we don't have many D impl yet (click >> to reveal more than the 12 first
 langs).
 You're also very welcome to add new idioms, as long as it's not
 D-specific, not tied to a library, and not a complex algorithm.
 UI works fine but is not perfect yet, so any feedback is also welcome.

 Cheers
   Val
Cool. I added a couple already, very easy to do. Note, it would be nice to have a way to link to docs for library functions used in the example. Demo and Origin links don't quite cut it. -Steve
Aug 20 2015
parent "Val" <admin programming-idioms.org> writes:
On Thursday, 20 August 2015 at 15:21:12 UTC, Steven Schveighoffer 
wrote:
 Note, it would be nice to have a way to link to docs for 
 library functions used in the example. Demo and Origin links 
 don't quite cut it.
Steve, I agree with you so I added the Doc link. https://github.com/Deleplace/programming-idioms/issues/2
Aug 21 2015
prev sibling parent reply "Val" <admin programming-idioms.org> writes:
Very good suggestions. I'll use the Github tracker to manage them 
:
https://github.com/Deleplace/programming-idioms/issues/1  (dice 
icon)
https://github.com/Deleplace/programming-idioms/issues/2  (link 
to doc)

Yes the website partially overlaps the purpose of Rosetta Code, 
but still has a lot of differences and a different approach. 
Let's says Programming-Idioms is for short snippets, and in only 
30 popular languages, not 584.

Thanks to your contributions, in only a couple of minutes D 
jumped at the 10th position of the most populated language in the 
site. Great!!
Aug 20 2015
parent "Val" <admin programming-idioms.org> writes:
 Thanks to your contributions, in only a couple of minutes D 
 jumped at the 10th position of the most populated language in 
 the site. Great!!
6th position actually! Another couple of minutes later. You guys rock.
Aug 20 2015