Re: Why are homepage examples too complicated?

2016-10-22 Thread Chris via Digitalmars-d
On Friday, 21 October 2016 at 23:08:06 UTC, Benjiro wrote: On Thursday, 20 October 2016 at 09:10:10 UTC, Chris wrote: O, that webshop that now needs a rewrite from zero, was a direct result of another outsource. Yay! And the client ends up paying ( again ) for that. Some things never chan

Re: Why are homepage examples too complicated?

2016-10-21 Thread Benjiro via Digitalmars-d
On Thursday, 20 October 2016 at 09:10:10 UTC, Chris wrote: I.e. "He agrees with me, therefore I like him!" One year of meetings to design a website does not necessarily mean the site's good or that it has to take at least a year until you have a presentable website. Sorry, was too busy with s

Re: Why are homepage examples too complicated?

2016-10-21 Thread Chris via Digitalmars-d
On Friday, 21 October 2016 at 12:31:00 UTC, Mark wrote: I second that. Also, it may be a good idea to simply use classical algorithms (binary search, quicksort, etc.), written in "D style", as examples. The typical visitor is probably familiar with these algorithms and thus the foreign synta

Re: Why are homepage examples too complicated?

2016-10-21 Thread Mark via Digitalmars-d
On Friday, 21 October 2016 at 10:24:40 UTC, Chris wrote: On Thursday, 20 October 2016 at 21:52:09 UTC, Andrei Alexandrescu wrote: On 10/20/2016 04:16 PM, Karabuta wrote: We can't assume all beginners come from imperative languages. D beginners may come from languages where the idiomatic way

Re: Why are homepage examples too complicated?

2016-10-21 Thread Chris via Digitalmars-d
On Thursday, 20 October 2016 at 21:52:09 UTC, Andrei Alexandrescu wrote: On 10/20/2016 04:16 PM, Karabuta wrote: We can't assume all beginners come from imperative languages. D beginners may come from languages where the idiomatic way of doing things is by means of pipelines. Generally it's

Re: Why are homepage examples too complicated?

2016-10-20 Thread Andrei Alexandrescu via Digitalmars-d
On 10/20/2016 04:16 PM, Karabuta wrote: On Thursday, 20 October 2016 at 19:52:32 UTC, Andrei Alexandrescu wrote: On 10/20/2016 03:48 PM, Karabuta wrote: On Thursday, 20 October 2016 at 14:04:06 UTC, Andrei Alexandrescu wrote: On 10/20/2016 07:38 AM, Nick Treleaven wrote: On Sunday, 16 October

Re: Why are homepage examples too complicated?

2016-10-20 Thread Karabuta via Digitalmars-d
On Thursday, 20 October 2016 at 19:52:32 UTC, Andrei Alexandrescu wrote: On 10/20/2016 03:48 PM, Karabuta wrote: On Thursday, 20 October 2016 at 14:04:06 UTC, Andrei Alexandrescu wrote: On 10/20/2016 07:38 AM, Nick Treleaven wrote: On Sunday, 16 October 2016 at 16:07:19 UTC, Nick Treleaven wro

Re: Why are homepage examples too complicated?

2016-10-20 Thread Andrei Alexandrescu via Digitalmars-d
On 10/20/2016 03:48 PM, Karabuta wrote: On Thursday, 20 October 2016 at 14:04:06 UTC, Andrei Alexandrescu wrote: On 10/20/2016 07:38 AM, Nick Treleaven wrote: On Sunday, 16 October 2016 at 16:07:19 UTC, Nick Treleaven wrote: I think this example is a bit awkward for D newbies to decipher. I th

Re: Why are homepage examples too complicated?

2016-10-20 Thread Karabuta via Digitalmars-d
On Thursday, 20 October 2016 at 14:04:06 UTC, Andrei Alexandrescu wrote: On 10/20/2016 07:38 AM, Nick Treleaven wrote: On Sunday, 16 October 2016 at 16:07:19 UTC, Nick Treleaven wrote: I think this example is a bit awkward for D newbies to decipher. I think here we are showing D's ctRegex; drop

Re: Why are homepage examples too complicated?

2016-10-20 Thread Chris via Digitalmars-d
On Thursday, 20 October 2016 at 14:04:06 UTC, Andrei Alexandrescu wrote: On 10/20/2016 07:38 AM, Nick Treleaven wrote: On Sunday, 16 October 2016 at 16:07:19 UTC, Nick Treleaven wrote: I think this example is a bit awkward for D newbies to decipher. I think here we are showing D's ctRegex; drop

Re: Why are homepage examples too complicated?

2016-10-20 Thread Andrei Alexandrescu via Digitalmars-d
On 10/20/2016 07:38 AM, Nick Treleaven wrote: On Sunday, 16 October 2016 at 16:07:19 UTC, Nick Treleaven wrote: I think this example is a bit awkward for D newbies to decipher. I think here we are showing D's ctRegex; dropping the functional map and lambdas would make this more universally under

Re: Why are homepage examples too complicated?

2016-10-20 Thread Chris via Digitalmars-d
On Thursday, 20 October 2016 at 11:38:04 UTC, Nick Treleaven wrote: On Sunday, 16 October 2016 at 16:07:19 UTC, Nick Treleaven wrote: I think this example is a bit awkward for D newbies to decipher. I think here we are showing D's ctRegex; dropping the functional map and lambdas would make this

Re: Why are homepage examples too complicated?

2016-10-20 Thread Nick Treleaven via Digitalmars-d
On Sunday, 16 October 2016 at 16:07:19 UTC, Nick Treleaven wrote: I think this example is a bit awkward for D newbies to decipher. I think here we are showing D's ctRegex; dropping the functional map and lambdas would make this more universally understood. https://github.com/dlang/dlang.org/p

Re: Why are homepage examples too complicated?

2016-10-20 Thread Chris via Digitalmars-d
On Wednesday, 19 October 2016 at 09:51:50 UTC, Benjiro wrote: The current homepage example is in my option, right between group 2 and 3. And its disregarding group one and two. What about setting up snippets about things people want to know about straight away like: 1. OOP 2. Functional pr

Re: Why are homepage examples too complicated?

2016-10-20 Thread Chris via Digitalmars-d
On Wednesday, 19 October 2016 at 20:46:08 UTC, Karabuta wrote: On Wednesday, 19 October 2016 at 09:28:28 UTC, Benjiro wrote: On Tuesday, 18 October 2016 at 20:51:24 UTC, Karabuta wrote: [...] True. Anybody can make a website. A website that is efficient, takes time. A stupid travel booking w

Re: Why are homepage examples too complicated?

2016-10-19 Thread Karabuta via Digitalmars-d
On Wednesday, 19 October 2016 at 09:28:28 UTC, Benjiro wrote: On Tuesday, 18 October 2016 at 20:51:24 UTC, Karabuta wrote: [...] True. Anybody can make a website. A website that is efficient, takes time. A stupid travel booking website took over a year with constant meeting to design around

Re: Why are homepage examples too complicated?

2016-10-19 Thread Chris via Digitalmars-d
On Wednesday, 19 October 2016 at 11:30:03 UTC, rikki cattermole wrote: On 20/10/2016 12:08 AM, Andrei Alexandrescu wrote: On that note, maybe we should setup a 'real code' pool so people can see real code, preferably on a few files big that does a specific but useful task. Actually, that'd b

Re: Why are homepage examples too complicated?

2016-10-19 Thread rikki cattermole via Digitalmars-d
On 20/10/2016 12:08 AM, Andrei Alexandrescu wrote: On 10/19/16 5:28 AM, Benjiro wrote: No offense to Andrei, while his is funny, he is simply thinking above my head. Walter is actually better at explain things. None taken! And thanks for your feedback. I think you have an easy means of helping

Re: Why are homepage examples too complicated?

2016-10-19 Thread Andrei Alexandrescu via Digitalmars-d
On 10/19/16 5:28 AM, Benjiro wrote: No offense to Andrei, while his is funny, he is simply thinking above my head. Walter is actually better at explain things. None taken! And thanks for your feedback. I think you have an easy means of helping progress here. Simply send more code snippets for

Re: Why are homepage examples too complicated?

2016-10-19 Thread Chris via Digitalmars-d
On Wednesday, 19 October 2016 at 09:51:50 UTC, Benjiro wrote: [snip] And no offense but basic D is just the same as basic PHP. They are all C languages. If somebody can start in PHP, they can start in D. The big difference is that there is much more materials available for PHP, so people mor

Re: Why are homepage examples too complicated?

2016-10-19 Thread Benjiro via Digitalmars-d
On Wednesday, 19 October 2016 at 09:32:29 UTC, Chris wrote: At the beginning, D was not meant to be a "first language", but this has changed over time. In fact, almost all new modern languages that emerge now have features that D has, like templates, !boo ;), so beginners will have to learn t

Re: Why are homepage examples too complicated?

2016-10-19 Thread Chris via Digitalmars-d
On Tuesday, 18 October 2016 at 20:51:24 UTC, Karabuta wrote: On Tuesday, 18 October 2016 at 10:04:35 UTC, Benjiro wrote: On Tuesday, 18 October 2016 at 09:26:56 UTC, Chris wrote: The issue is, that in order to understand the example, you are already required to have a knowledge of the languag

Re: Why are homepage examples too complicated?

2016-10-19 Thread Benjiro via Digitalmars-d
On Tuesday, 18 October 2016 at 20:51:24 UTC, Karabuta wrote: They will not understand. Those are the UX stuff you learn when you are a web designer/developer. True. Anybody can make a website. A website that is efficient, takes time. A stupid travel booking website took over a year with con

Re: Why are homepage examples too complicated?

2016-10-19 Thread Chris via Digitalmars-d
On Tuesday, 18 October 2016 at 12:49:55 UTC, Benjiro wrote: When people have a choice between a multitude of website, programming languages, ... people make choices fast. [snip] There are three things here. First, you initially made your decision not to use D based not only on the homepage (on

Re: Why are homepage examples too complicated?

2016-10-18 Thread Karabuta via Digitalmars-d
On Tuesday, 18 October 2016 at 10:04:35 UTC, Benjiro wrote: On Tuesday, 18 October 2016 at 09:26:56 UTC, Chris wrote: The issue is, that in order to understand the example, you are already required to have a knowledge of the language. I can only use myself as a example. Only started to reall

Re: Why are homepage examples too complicated?

2016-10-18 Thread MakersF via Digitalmars-d
On Tuesday, 18 October 2016 at 15:41:29 UTC, Jesse Phillips wrote: On Monday, 17 October 2016 at 20:13:19 UTC, Karabuta wrote: I would suggest they remove all templates and make it its own example. * Basic functional/ranges example = map, filter, reduce Templates * basic helloworld = wr

Re: Why are homepage examples too complicated?

2016-10-18 Thread Jesse Phillips via Digitalmars-d
On Monday, 17 October 2016 at 20:13:19 UTC, Karabuta wrote: I would suggest they remove all templates and make it its own example. * Basic functional/ranges example = map, filter, reduce Templates * basic helloworld = write the string "Hello, World!" Template (implicit) * Basic sort

Re: Why are homepage examples too complicated?

2016-10-18 Thread Benjiro via Digitalmars-d
When people have a choice between a multitude of website, programming languages, ... people make choices fast. Personally moved over 5 different programming languages in 3 months time trying to find the ideal match. So my attention span is not exactly small. But when faced with a entire series

Re: Why are homepage examples too complicated?

2016-10-18 Thread Chris via Digitalmars-d
On Tuesday, 18 October 2016 at 10:04:35 UTC, Benjiro wrote: The issue is, that in order to understand the example, you are already required to have a knowledge of the language. I can only use myself as a example. Only started to really use D a few days ago because i have a specific project.

Re: Why are homepage examples too complicated?

2016-10-18 Thread Benjiro via Digitalmars-d
On Tuesday, 18 October 2016 at 09:26:56 UTC, Chris wrote: I think the point of the examples is to show D at its most expressive/concise. The thing is that if you presented "Hello, world!" a lot of people who come from other languages would complain about how D doesn't seem to have chaining, map

Re: Why are homepage examples too complicated?

2016-10-18 Thread Chris via Digitalmars-d
On Thursday, 13 October 2016 at 19:06:26 UTC, Karabuta wrote: I assume the purpose for those demonstrations are to win the interest of the user as to how easy and clean D code can be. Then why; // Round floating point numbers import std.algorithm, std.conv, std.functional, std.math, std.re

Re: Why are homepage examples too complicated?

2016-10-17 Thread Karabuta via Digitalmars-d
On Monday, 17 October 2016 at 19:39:14 UTC, Benjiro wrote: On Thursday, 13 October 2016 at 19:06:26 UTC, Karabuta wrote: How is a new visitor supposed to know "!" is for templates and not some complicated syntax? As a dlang newbie ( only started to learn a few days ago ), the example on the f

Re: Why are homepage examples too complicated?

2016-10-17 Thread Karabuta via Digitalmars-d
On Sunday, 16 October 2016 at 12:14:34 UTC, Adam D. Ruppe wrote: On Friday, 14 October 2016 at 21:18:45 UTC, Karabuta wrote: The "!" is more trouble than good (IMO for the majority). @Adam Roupe did a talk at previous DConf which he testifies to this. Couldn't be me, I don't think I ever tal

Re: Why are homepage examples too complicated?

2016-10-17 Thread Benjiro via Digitalmars-d
On Thursday, 13 October 2016 at 19:06:26 UTC, Karabuta wrote: How is a new visitor supposed to know "!" is for templates and not some complicated syntax? As a dlang newbie ( only started to learn a few days ago ), the example on the front page is just complex for new users. Its not a lack of

Re: Why are homepage examples too complicated?

2016-10-16 Thread Nick Treleaven via Digitalmars-d
On Sunday, 16 October 2016 at 16:07:19 UTC, Nick Treleaven wrote: // Chain functions together to round a string parsed as a real number alias roundString = pipe!(to!real, std.math.round, to!string); In fact if we're just printing the rounded numbers, we can drop to!string and inline roundStri

Re: Why are homepage examples too complicated?

2016-10-16 Thread Nick Treleaven via Digitalmars-d
On Thursday, 13 October 2016 at 19:06:26 UTC, Karabuta wrote: // Replace anything that looks like a real // number with the rounded equivalent. stdin .byLine .map!(l => l.replaceAll!(c => c.hit.round) (reFloatingPoint)) .each!wri

Re: Why are homepage examples too complicated?

2016-10-16 Thread Adam D. Ruppe via Digitalmars-d
On Friday, 14 October 2016 at 21:18:45 UTC, Karabuta wrote: The "!" is more trouble than good (IMO for the majority). @Adam Roupe did a talk at previous DConf which he testifies to this. Couldn't be me, I don't think I ever talked about it... and I'm actually pro-!. It is a perfectly fine sy

Re: Why are homepage examples too complicated?

2016-10-16 Thread Karabuta via Digitalmars-d
On Thursday, 13 October 2016 at 22:12:42 UTC, Guillaume Piolat wrote: On Thursday, 13 October 2016 at 19:06:26 UTC, Karabuta wrote: I agree, something friendly and familiar would be called for. Instead we have weird float-rounding programs. The goal of such program should be to push the read

Re: Why are homepage examples too complicated?

2016-10-13 Thread Guillaume Piolat via Digitalmars-d
On Thursday, 13 October 2016 at 19:06:26 UTC, Karabuta wrote: I assume the purpose for those demonstrations are to win the interest of the user as to how easy and clean D code can be. Then why; // Round floating point numbers import std.algorithm, std.conv, std.functional, std.math, std.re

Re: Why are homepage examples too complicated?

2016-10-13 Thread cym13 via Digitalmars-d
On Thursday, 13 October 2016 at 19:06:26 UTC, Karabuta wrote: I assume the purpose for those demonstrations are to win the interest of the user as to how easy and clean D code can be. Then why; // Round floating point numbers import std.algorithm, std.conv, std.functional, std.math, std.re

Re: Why are homepage examples too complicated?

2016-10-13 Thread Karabuta via Digitalmars-d
On Thursday, 13 October 2016 at 19:30:30 UTC, Meta wrote: On Thursday, 13 October 2016 at 19:06:26 UTC, Karabuta wrote: How's a new user supposed to know <> is for templates when looking at a C++ example? They don't; it's just something that has to be learned, ... Does that make it a standa

Re: Why are homepage examples too complicated?

2016-10-13 Thread Meta via Digitalmars-d
On Thursday, 13 October 2016 at 19:06:26 UTC, Karabuta wrote: I assume the purpose for those demonstrations are to win the interest of the user as to how easy and clean D code can be. Then why; // Round floating point numbers import std.algorithm, std.conv, std.functional, std.math, std.re

Why are homepage examples too complicated?

2016-10-13 Thread Karabuta via Digitalmars-d
I assume the purpose for those demonstrations are to win the interest of the user as to how easy and clean D code can be. Then why; // Round floating point numbers import std.algorithm, std.conv, std.functional, std.math, std.regex, std.stdio; alias round = pipe!(to!real, std.math.round, t