digitalmars.D - D.challenge
- Justin Johansson (29/29) Aug 25 2010 I propose and hereby petition Walter to set up a sub D newsgroup
- Andrej Mitrovic (12/41) Aug 27 2010 I like this idea. I don't know about showing off "superiority" of D,
- Justin Johansson (10/15) Sep 01 2010 Yes, well, of course I meant to enquote 'superiority' as you rightly
- Philippe Sigaud (8/8) Aug 28 2010 It's a fun idea! Why not just post with '[challenge]' in the object?
- Justin Johansson (13/21) Aug 28 2010 Maybe challenges on their own might be a bit sparse in number,
- bearophile (17/20) Aug 31 2010 In past months I have proposed two little challenges, the second of them...
I propose and hereby petition Walter to set up a sub D newsgroup called D.challenge which purpose is to make for a more-specific forum (rather than the generic d.D) for topics which are related to discussion about "challenging D to do this or that" in the context of, say, another programming language or some CS problem. My concept of D.challenge is to try and lift the quality of the discussion to a higher plane whereby D can show its superiority over other languages (esp. in the Algol and curly-bracey family of PLs) and/or otherwise be challenged to prevail or fail in some sort of language/CS problem shoot-out. Recent time ago people (e.g. Nick Sabalausky), and others at times before them (e.g. myself/Justin Johansson), have suggested that the d.D newsgroup be split up into different subgroups for the purpose of focusing discussions towards achieving better outcomes but to no avail. <sigh/> So as a presumptive strike upon this ng, I propose that the subgroup D.challenge be instantiated as a place of higher ground for (D) language criticisms and shootouts to play out. Who's up to the D.challenge and, if the idea has legs, can we agree on some charter for this D subforum? Of course, at the end of the day, D is Walter Bright's baby and naturally it would be up to W to commission and sanction "D.challenge". Still, I think, promoted effectively, "D.challenge" could become a good marketing vehicle for D. Cheers, Justin Johansson
Aug 25 2010
I like this idea. I don't know about showing off "superiority" of D, but it would be a good way to learn from each other. E.g. one could submit a solution to a challenge, and then others can refine it to be safer/faster/better in some regards if they want to, while others present their solutions that take a different approach. I know stackoverflow tends to have challenges, but theirs is so often orriented around the goal of reaching less "lines of code". I'd prefer if we had different challenges instead of focusing on only one thing. An example of a challenge would be "here's some unsafe code that does x and y, the challenge is to make it safe and perform the same operations" or something like that. Anyway, vote++ from me. On Wed, Aug 25, 2010 at 6:32 PM, Justin Johansson <no spam.com> wrote:I propose and hereby petition Walter to set up a sub D newsgroup called D.challenge which purpose is to make for a more-specific forum (rather than the generic d.D) for topics which are related to discussion about "challenging D to do this or that" in the context of, say, another programming language or some CS problem. My concept of D.challenge is to try and lift the quality of the discussion to a higher plane whereby D can show its superiority over other languages (esp. in the Algol and curly-bracey family of PLs) and/or otherwise be challenged to prevail or fail in some sort of language/CS problem shoot-out. Recent time ago people (e.g. Nick Sabalausky), and others at times before them (e.g. myself/Justin Johansson), have suggested that the d.D newsgroup be split up into different subgroups for the purpose of focusing discussions towards achieving better outcomes but to no avail. <sigh/> So as a presumptive strike upon this ng, I propose that the subgroup D.challenge be instantiated as a place of higher ground for (D) language criticisms and shootouts to play out. Who's up to the D.challenge and, if the idea has legs, can we agree on some charter for this D subforum? Of course, at the end of the day, D is Walter Bright's baby and naturally it would be up to W to commission and sanction "D.challenge". =A0Still, I think, promoted effectively, "D.challenge" could become a good marketing vehicle for D. Cheers, Justin Johansson
Aug 27 2010
On 28/08/10 06:45, Andrej Mitrovic wrote:I like this idea. I don't know about showing off "superiority" of D, but it would be a good way to learn from each other. E.g. one could submit a solution to a challenge, and then others can refine it to be safer/faster/better in some regards if they want to, while others present their solutions that take a different approach.Yes, well, of course I meant to enquote 'superiority' as you rightly did. Naturally "superiority" of any PL is dependent upon, or subjective within, the application domain which a PL purports itself to excel in (over and above other PLs which compete in the same application domain). To set the record straight, may it now be asked (without prejudice :-)) that we qualify what application domain(s) D purports to excel in? Cheers Justin Johansson
Sep 01 2010
It's a fun idea! Why not just post with '[challenge]' in the object? People not interested in such threads can skip them easily. I also propose '[D tricks]' as another meta-subject. For example, did you know you can have import statements in structs (maybe also in classes, I don't know)? That way, you can put an Importer struct in a template to give it access to std functions you need, even when the template is mixed in another scope. Philippe
Aug 28 2010
On 28/08/10 17:21, Philippe Sigaud wrote:It's a fun idea! Why not just post with '[challenge]' in the object? People not interested in such threads can skip them easily. I also propose '[D tricks]' as another meta-subject. For example, did you know you can have import statements in structs (maybe also in classes, I don't know)? That way, you can put an Importer struct in a template to give it access to std functions you need, even when the template is mixed in another scope. PhilippeMaybe challenges on their own might be a bit sparse in number, so perhaps tricks & challenges combined in one forum would be more substantial? Then again just posting with either [challenge] or [trick] in the subject line might do the trick (excuse the pun) .. in which case D.learn might be the appropriate forum for these suggested subject annotations, especially also since the traffic on D.learn is quite low and people wanting to learn or advance their D knowledge might find D.learn at little more interesting with a sprinkling of tricks and challenges. Cheers Justin Johansson
Aug 28 2010
Justin Johansson:"challenging D to do this or that" in the context of, say, another programming language or some CS problem.In past months I have proposed two little challenges, the second of them was to implement this RosettaCode task in D, to produce a program that is faster, shorter and uses less memory than the current D version: http://rosettacode.org/wiki/Hamming_numbers#D If you take a look at the Haskell version (that is much faster and uses much less RAM and has a shorter source code) you see that there is lot of space for improvement: hamming = 1 : map (2*) hamming `merge` map (3*) hamming `merge` map (5*) hamming where merge (x:xs) (y:ys) | x < y = x : xs `merge` (y:ys) | x > y = y : (x:xs) `merge` ys | otherwise = x : xs `merge` ys main = do print $ take 20 hamming print $ hamming !! 1690 print $ hamming !! 999999 (I don't remember yet the other older challenge.) Bye, bearophile
Aug 31 2010