Re: Beginner ?. Why does D suggest to learn java

2014-10-22 Thread Kagamin via Digitalmars-d-learn
On Tuesday, 21 October 2014 at 21:58:09 UTC, ketmar via 
Digitalmars-d-learn wrote:
start from using templates as generics, then add some sugar, 
some type
consitions, some CTFE and so on. with C# we will stop right 
after

generics, 'cause there is no other things there.


That's quite inadequate criticism. If you don't know, what 
features generics have, you can't criticize them.


Re: Beginner ?. Why does D suggest to learn java

2014-10-22 Thread Dejan Lekic via Digitalmars-d-learn

On Thursday, 16 October 2014 at 22:26:51 UTC, RBfromME wrote:
I'm a newbie to programming and have been looking into the D 
lang as a general purposing language to learn, yet the D 
overview indicates that java would be a better language to 
learn for your first programming language. Why?  Looks like D 
is easier than Java...


D is far more complex programming language than Java. I do D 
programming for over decade, and Java for ~9 years (before I was 
a C++ programmmer). Just take a look at number of types you have 
in D, storage classes, pointers, modules (that will soon come to 
Java too), etc... D generics are superior to Java. However, Java 
generics are superasy.


Java is designed to be an easy programming language, D is 
designed to be pragmatic. If people new to programming were about 
to start with D as the first language, I suggest them to start 
with an easy subset of it, and I humbly believe that subset will 
look very, very similar to Java.


PS. this is not Java advocacy here, I am just trying to be fair 
and realistic. I just love D but if I said D is as easy as Java, 
that would be a lie.


Re: Beginner ?. Why does D suggest to learn java

2014-10-22 Thread via Digitalmars-d-learn
On Tuesday, 21 October 2014 at 12:19:43 UTC, ketmar via 
Digitalmars-d-learn wrote:
templates arent about FP only. yet i agree that Scheme is a 
very good starting point, SICP rocks.


It is available for free online:

http://mitpress.mit.edu/sicp/

Scheme is good for teaching because it is a minimalistic 
language, so you quickly learn the semantic model which is more 
hidden in Haskell.


But I really enjoyed this one:

http://tryhaskell.org/

D should have a similar intro when the current quirks have been 
ironed out.


Re: Beginner ?. Why does D suggest to learn java

2014-10-22 Thread ketmar via Digitalmars-d-learn
On Wed, 22 Oct 2014 07:58:49 +
Kagamin via Digitalmars-d-learn digitalmars-d-learn@puremagic.com
wrote:

 That's quite inadequate criticism. If you don't know, what 
 features generics have, you can't criticize them.
i'm don't saying that generics are bad, i'm saying that D has alot
more anyway with it's CTFE magic. and generics aren't metaprogramming
tool. but my memory can be weak, so feel free to correct me.


signature.asc
Description: PGP signature


Re: Beginner ?. Why does D suggest to learn java

2014-10-21 Thread Kapps via Digitalmars-d-learn

On Thursday, 16 October 2014 at 22:26:51 UTC, RBfromME wrote:
I'm a newbie to programming and have been looking into the D 
lang as a general purposing language to learn, yet the D 
overview indicates that java would be a better language to 
learn for your first programming language. Why?  Looks like D 
is easier than Java...


Honestly, I'd recommend starting with VB.net or C# (preferably 
C#) over D, as:

1) They're simpler, no template magic, not as low level, etc.
2) Having an excellent IDE is very nice for starting out, seeing 
errors right as you type them, seeing all the methods and how to 
call them, having the documentation right there in your IDE, and 
not having to worry about whether what you just wrote is 
something that the IDE's parser can't handle or is actually 
invalid code.
3) Being significantly more popular is in general a boon, more 
tutorials are available (though D has some nice resources like 
Ali's book), and you're more likely to find a solution to a 
problem through Google as more people have come across it.
4) Having to deal with any compiler bugs would be very 
frustrating when starting to learn programming. D still has 
plenty, even if they're much less noticeable now. Trying to 
figure out why something doesn't work only to realize it's a 
compiler bug is frustrating.
5) Having a drag-and-drop GUI designer is very nice. D is still 
difficult to use for GUIs, and when starting it's really nice to 
see something significant on the screen right away.
6) You probably won't use most of D's features when you're just 
learning, so much of D's advantages are gone.


D is an awesome language, but I would not recommend it for 
someone completely new to programming. Once you get the hang of 
programming, D is an excellent language, until then something 
simpler, more popular, and more supported, would be better.


Re: Beginner ?. Why does D suggest to learn java

2014-10-21 Thread ketmar via Digitalmars-d-learn
On Tue, 21 Oct 2014 09:01:32 +
Kapps via Digitalmars-d-learn digitalmars-d-learn@puremagic.com wrote:

 no template magic
that's very bad. it's time to stop making people think that templates
are inevitably arcane.


signature.asc
Description: PGP signature


Re: Beginner ?. Why does D suggest to learn java

2014-10-21 Thread Paulo Pinto via Digitalmars-d-learn
On Tuesday, 21 October 2014 at 09:14:08 UTC, ketmar via 
Digitalmars-d-learn wrote:

On Tue, 21 Oct 2014 09:01:32 +
Kapps via Digitalmars-d-learn 
digitalmars-d-learn@puremagic.com wrote:



no template magic
that's very bad. it's time to stop making people think that 
templates

are inevitably arcane.



People think templates are magic, due to their skillset.

I see that all the time in the enterprise, when we get people on 
projects that would already have issues using something like 
Clipper/VB back in the day.


--
paulo



Re: Beginner ?. Why does D suggest to learn java

2014-10-21 Thread ketmar via Digitalmars-d-learn
On Tue, 21 Oct 2014 11:20:42 +
Paulo Pinto via Digitalmars-d-learn digitalmars-d-learn@puremagic.com
wrote:

 People think templates are magic, due to their skillset.
and other people keep pointing at languages without templates and
metaprogramming as good for learing. it's closed circle.


signature.asc
Description: PGP signature


Re: Beginner ?. Why does D suggest to learn java

2014-10-21 Thread via Digitalmars-d-learn
On Tuesday, 21 October 2014 at 11:43:56 UTC, ketmar via 
Digitalmars-d-learn wrote:
and other people keep pointing at languages without templates 
and metaprogramming as good for learing. it's closed circle.


The problem with template-programming in XSLT/C++/D is that if 
you want to learn functional programming you are better off using 
a good functional language.


Re: Beginner ?. Why does D suggest to learn java

2014-10-21 Thread ketmar via Digitalmars-d-learn
On Tue, 21 Oct 2014 11:51:16 +
via Digitalmars-d-learn digitalmars-d-learn@puremagic.com wrote:

 The problem with template-programming in XSLT/C++/D is that if 
 you want to learn functional programming you are better off using 
 a good functional language.
templates arent about FP only. yet i agree that Scheme is a very good
starting point, SICP rocks.


signature.asc
Description: PGP signature


Re: Beginner ?. Why does D suggest to learn java

2014-10-21 Thread Kapps via Digitalmars-d-learn
On Tuesday, 21 October 2014 at 09:14:08 UTC, ketmar via 
Digitalmars-d-learn wrote:

On Tue, 21 Oct 2014 09:01:32 +
Kapps via Digitalmars-d-learn 
digitalmars-d-learn@puremagic.com wrote:



no template magic
that's very bad. it's time to stop making people think that 
templates

are inevitably arcane.


I like D's templates, it's one of the things that makes me like D 
more than C#. But they can definitely get quite complex. C# 
limits templates to generic types, like Listint, and for a 
beginner I think that's an easier way to handle things.


Re: Beginner ?. Why does D suggest to learn java

2014-10-21 Thread ketmar via Digitalmars-d-learn
On Tue, 21 Oct 2014 21:48:14 +
Kapps via Digitalmars-d-learn digitalmars-d-learn@puremagic.com wrote:

 I like D's templates, it's one of the things that makes me like D 
 more than C#. But they can definitely get quite complex. C# 
 limits templates to generic types, like Listint, and for a 
 beginner I think that's an easier way to handle things.
nobody forcec any beginner to write complex templates from the start.
not even use them: alot of things can be done without phobos, as
excercises. yet i think that it's good to start with the language that
has powerful templates and metaprogramming, so more and more advanced
features can be gently introduced when there is time.

we can't (ok, we can, but this is very-very hard) teach people how to
use metaprogramming properly if their language of choice aren't
supporting metaprogramming at all, for example.

start from using templates as generics, then add some sugar, some type
consitions, some CTFE and so on. with C# we will stop right after
generics, 'cause there is no other things there.


signature.asc
Description: PGP signature


Re: Beginner ?. Why does D suggest to learn java

2014-10-21 Thread ketmar via Digitalmars-d-learn
On Wed, 22 Oct 2014 00:57:59 +0300
ketmar via Digitalmars-d-learn digitalmars-d-learn@puremagic.com
wrote:

 consitions
i don't even know what this word means. honestly.


signature.asc
Description: PGP signature


Re: Beginner ?. Why does D suggest to learn java

2014-10-20 Thread Kagamin via Digitalmars-d-learn

On Friday, 17 October 2014 at 23:31:46 UTC, Joakim wrote:
Tablets are optimized for basic usage, not saving files and 
document editing and whatever else you might want to do on a 
PC.  Most people just need a basic appliance that isn't going 
to catch viruses or require registry hacks.


LOL 
http://wmpoweruser.com/infected-android-phones-now-outnumber-infected-pcs-on-mobile-networks/


Re: Beginner ?. Why does D suggest to learn java

2014-10-20 Thread Joakim via Digitalmars-d-learn

On Monday, 20 October 2014 at 13:52:10 UTC, Kagamin wrote:

On Friday, 17 October 2014 at 23:31:46 UTC, Joakim wrote:
Tablets are optimized for basic usage, not saving files and 
document editing and whatever else you might want to do on a 
PC.  Most people just need a basic appliance that isn't going 
to catch viruses or require registry hacks.


LOL 
http://wmpoweruser.com/infected-android-phones-now-outnumber-infected-pcs-on-mobile-networks/


Are you laughing because of this? :)

Android devices accounted for 60% of total mobile network 
infections, and 40% of mobile malware originated from Windows 
laptops connected to a phone or connected directly through a 
mobile USB stick or W-Fi hub.


Infections on Windows Phone, iPhone and BlackBerry devices made 
up less than 1%


'Android smartphones are the easiest malware target,' said Kevin 
McNamee, security architect and director of Alcatel-Lucent’s 
Kindsight Security Labs, but noted 'but Windows laptops are still 
the favourite of hard core professional cybercriminals.'”


Note my original reference to not being able to save files and 
the very low rate of infection on the iPhone.  Android is a 
little different because it's so open, just like Windows, and I 
bet most of those infected Android devices were rooted or old.  
If you do the math, there are a lot more Android devices than 
Windows laptops, so the fact that there are almost as many 
infected Windows laptops means the infection rate of Windows is 
much higher.


Re: Beginner ?. Why does D suggest to learn java

2014-10-20 Thread Mitch Crane via Digitalmars-d-learn
On Mon, Oct 20, 2014 at 2:40 PM, Joakim via Digitalmars-d-learn
digitalmars-d-learn@puremagic.com wrote:
 On Monday, 20 October 2014 at 13:52:10 UTC, Kagamin wrote:

 If you do the math, there are a lot more Android
 devices than Windows laptops, so the fact that there are almost as many
 infected Windows laptops means the infection rate of Windows is much higher.

All the more, those numbers reflecting infection rates on mobile networks.


Re: Beginner ?. Why does D suggest to learn java

2014-10-19 Thread HaraldZealot via Digitalmars-d-learn

On Thursday, 16 October 2014 at 22:26:51 UTC, RBfromME wrote:
I'm a newbie to programming and have been looking into the D 
lang as a general purposing language to learn, yet the D 
overview indicates that java would be a better language to 
learn for your first programming language. Why?  Looks like D 
is easier than Java...


I have taught programming and programming language for several 
years, last 4 in University. In Belarus we have traditionally 
program that starts with C as subset of C++ (or even pure C), 
than C++ and only after that Java or C#. There are many 
high-qualified programmers, who absolve such program. Thus we 
have a proof, that even C can be first language. But in my 
opinion C is not the simplest way in programming for beginners. D 
is perfectly suite education purpose (in place of C and C++ of 
our belarusian program), because it has C-like syntax (Pascal 
hasn't), it is multi-paradigmal and has procedural-structural 
paradigm as C and C++ (but not Java or C#) and this paradigm is 
start point of programing for years, D also has more convenient 
and clearer syntax than C and C++. The main objection vs. dlang 
is that D is unpopular and probably you can't find job offer in 
this language. But this objection is weak, if D is your first 
language, because IT-student learn much more than one language 
during education, and D is very good start and view point for 
such languages as C/C++, Java and C#, the most popular 
professional languages. And many habits that will be learned in D 
(such is unittesting, contract programing and many others) will 
serve well in future for language without intrinsic support of 
these features.



RBfromME, I have interest to teach D as first language and also 
to teach foreigner. So if you want, I can tutor you through 
e-mail and github totally free.


harald_zea...@tut.by


Re: Beginner ?. Why does D suggest to learn java

2014-10-18 Thread via Digitalmars-d-learn

On Saturday, 18 October 2014 at 02:00:42 UTC, RBfromME wrote:
but i don't find the basics any easier to  learn than D's.  The 
biggest issue i personal find in getting deeper into  a 
language is the docs and examples. The python examples, beyond 
the basics usually get write into OO so you find your self 
trying to figure out OO while trying to sift through the 
examples.  Makes it a little harder to get going and figure out 
the available libraries while trying to figure OO at the same 
time.


If you find D more fun, then use D, but OO is little more than 
representing aspects of real physical objects in the computer:


If you want to write a program about cars you could group 
properties such as weight, top-speed and build-year and call that 
Vehicle, then add number of wheels and motorsize and call it Car 
or some other properties and call it Boat. Add a function print() 
to display all the info to each class Vehicle, Car and Boat. Then 
you can create a list of vehicles that store different properties 
for different types of vehicles while being able to treat all 
cars and boats the same when printing them.


That's basically it. Nothing magic.

The most important aspect of learning how to program is what 
universities tend to call datastructures and algorithms.  The 
basics is probably just 2-4 weeks.


If you already know Python a little bit you could try to use 
educational resources for Python and translate it into D, e.g.:


http://interactivepython.org/courselib/static/pythonds/index.html

The nice thing about Python that it is very close to what is 
called pseudo code, basically a shorthand used when sketching a 
program.


Summing it up, I personally think the hardest part in learning 
to use a specific language is the docs and and examples because 
they all throw you write into OO and you spend more time trying 
to figure out OO instead of how to use the standard lib or 
third party lib to get a basic task done.


You don't need to learn more OO than I wrote above, and perhaps 
not even that. What you need to learn to be productive in any 
imperative language is:


1. What an aggregate (of values) is, they are often called 
record, struct or class and how to create them.


2. Arrays and the provided operations on them (can be in language 
or libraries)


3. How to create links between aggregates (called references or 
pointers)


Then pick up an online course or book on data structures and 
algorithms. Introductory books and courses teach roughly the same 
stuff, so pick anyone you like.


Understanding libraries and their documentation becomes much 
easier when you know the basic terminology about data structures 
and algorithms. One of the most entertaining and useful courses 
in computer science.


Re: Beginner ?. Why does D suggest to learn java

2014-10-18 Thread Mike James via Digitalmars-d-learn

On Friday, 17 October 2014 at 08:44:00 UTC, Paulo  Pinto wrote:
On Friday, 17 October 2014 at 01:05:37 UTC, ketmar via 
Digitalmars-d-learn wrote:

On Fri, 17 Oct 2014 00:52:14 +
MachineCode via Digitalmars-d-learn 
digitalmars-d-learn@puremagic.com

wrote:

I don't understand. If at least it were C but java? why not D 
itself?
C is *awful* as beginner's language. never ever let people 
start with

C if you don't hate 'em.

as for D... current version of D can be used, but with some
precautions. we now have excellent book by Ali. (it's great, 
really! i
believe that it must be featured on the front dlang.org page!) 
but java

has alot more books and tutorials.

not that D is bad for beginners, it's just has a smaller 
userbase. and
all that things with classes are reference types and structs 
are not,
empty array is not empty array but is empty array and so on 
D may be
confusing a little. it's good to have some CS background to 
understood

that things.

just my cent and cent.



Better, go with FreePascal http://www.freepascal.org/ and 
discover all that those features that many C advocates spread 
as being close to the machine and other C only features, aren't 
exclusive of it.


Alongside support for real modules, OO and genericity.

Then with a head clean of bad C influences, jump into D.


--
Paulo


Don't tell him that - he may discover Freepascal/Lazarus is the 
holy grail of GUI programming and may never try D...  ;-)


-=mike=-


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread spir via Digitalmars-d-learn

On 17/10/14 07:38, maarten van damme via Digitalmars-d-learn wrote:

While d can be complex, there's nothing preventing you from starting out
simple and not using all features at first.
I don't understand why it's not suitable for a beginner if you use this
approach...


For some reasons, in my view: A beginner has to learn programming in addition to 
a first lang. A beginner has to learn a first lang in addition to programming. 
We learn languages by understanding valid, meaningful input, ie here reading 
code. All static langs introduce tons of complication only due to their 
staticity. D is rather big  complex, in the field of static langs. Most code 
will use more than a theoretical minimal set of features. And this minimal set 
is far more in size, difficulty, complication than in langs partly designed  for 
ease of learning (Lua, Python, Scheme...). Even plain C is far more difficult 
than say, Lua.


d



Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread via Digitalmars-d-learn
On Friday, 17 October 2014 at 05:38:51 UTC, maarten van damme via 
Digitalmars-d-learn wrote:
While d can be complex, there's nothing preventing you from 
starting out

simple and not using all features at first.
I don't understand why it's not suitable for a beginner if you 
use this

approach...


Anything that keeps you motivated is suitable, but for a beginner 
the goal should not be to  learn a language, but to learn 
programming principles and learn how to write clean programs.


Using a more uniform language that is suitable for teaching is 
better, and provides more educational resources. Where would you 
go to find examples of clean programming in D/C++?


For the first few weeks getting instant feedback from a REPL is 
gratifying and being constrained by a functional/recursive 
paradigm is good. Getting instant visual feedback is motivating 
and makes it easy to see where you go wrong. Nice for the first 
steps if you are a visual person.


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread spir via Digitalmars-d-learn

On 17/10/14 03:05, ketmar via Digitalmars-d-learn wrote:

On Fri, 17 Oct 2014 00:52:14 +
MachineCode via Digitalmars-d-learn digitalmars-d-learn@puremagic.com
wrote:


I don't understand. If at least it were C but java? why not D
itself?

C is *awful* as beginner's language. never ever let people start with
C if you don't hate 'em.

as for D... current version of D can be used, but with some
precautions. we now have excellent book by Ali. (it's great, really! i
believe that it must be featured on the front dlang.org page!) but java
has alot more books and tutorials.

not that D is bad for beginners, it's just has a smaller userbase. and
all that things with classes are reference types and structs are not,
empty array is not empty array but is empty array and so on D may be
confusing a little. it's good to have some CS background to understood
that things.


What you say here applies, I guess, to many other points. I applaud Ali for 
writing a tutorial like his but... Check it (just the first pages is enough) for 
literally the dozens of notions one must know and master for being able to 
understand, not only the features of D introduced, but even the tutorial itself. 
If I am not a programmer, and one who knows other static langs, and better of 
the mainstream procedural paradigm, if not D itself, then I do not understand 
more than few isolated words here and there. We are blind to the huge pile of 
concepts we know, I guess, because we know them, thus take them for granted...


d


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread bearophile via Digitalmars-d-learn

Ola Fosheim Grøstad:


The IDE support is probably a bit better with Java/C#


The importance of the IDE for the first language is 
controversial. I think it's not so important.



and using a statically typed language as your first language 
has advantages,


While no one has determined scientifically that you are right, I 
too believe that static typing has some advantages for a first 
language. I think there are no perfect first languages.


Bye,
bearophile


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread Paulo Pinto via Digitalmars-d-learn
On Friday, 17 October 2014 at 01:05:37 UTC, ketmar via 
Digitalmars-d-learn wrote:

On Fri, 17 Oct 2014 00:52:14 +
MachineCode via Digitalmars-d-learn 
digitalmars-d-learn@puremagic.com

wrote:

I don't understand. If at least it were C but java? why not D 
itself?
C is *awful* as beginner's language. never ever let people 
start with

C if you don't hate 'em.

as for D... current version of D can be used, but with some
precautions. we now have excellent book by Ali. (it's great, 
really! i
believe that it must be featured on the front dlang.org page!) 
but java

has alot more books and tutorials.

not that D is bad for beginners, it's just has a smaller 
userbase. and
all that things with classes are reference types and structs 
are not,
empty array is not empty array but is empty array and so on D 
may be
confusing a little. it's good to have some CS background to 
understood

that things.

just my cent and cent.



Better, go with FreePascal http://www.freepascal.org/ and 
discover all that those features that many C advocates spread as 
being close to the machine and other C only features, aren't 
exclusive of it.


Alongside support for real modules, OO and genericity.

Then with a head clean of bad C influences, jump into D.


--
Paulo


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread via Digitalmars-d-learn

On Friday, 17 October 2014 at 08:33:46 UTC, bearophile wrote:

The IDE support is probably a bit better with Java/C#


The importance of the IDE for the first language is 
controversial. I think it's not so important.


Perhaps it depends on the person and the language, but I would 
think autocompletion hints and getting visual cues of syntax 
errors important.


Error messages with line numbers can be overwhelming, hard to 
understand and discourage experimentation. Newbies often make 
many syntactical errors.


Even when doing interactive stuff in python I find ipython a lot 
more convenient than regular python. Insepecting a class by 
hitting tab is very useful for learning I think.


and using a statically typed language as your first language 
has advantages,


While no one has determined scientifically that you are right, 
I too believe that static typing has some advantages for a 
first language. I think there are no perfect first languages.


That's probably right, because motivation is the most important 
factor. So even matlab can be a nice environment for learning if 
it fits your interests.


In general I think Dart could turn into a nice language for 
beginners. It is dynamic and a bit forgiving, but has static 
checking and you can see the results right in your browser (and 
debug it). But I think the IDE should be mandatory…




Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread Chris via Digitalmars-d-learn

On Thursday, 16 October 2014 at 22:26:51 UTC, RBfromME wrote:
I'm a newbie to programming and have been looking into the D 
lang as a general purposing language to learn, yet the D 
overview indicates that java would be a better language to 
learn for your first programming language. Why?  Looks like D 
is easier than Java...


I agree with Ali. Give it a try, you don't need to use all the 
fancy features of D, features you only come to appreciate after 
years of programming (especially in other languages like Java, 
that are very restrictive).


In D you can start out with very simple code like

import std.stdio;

void main() {
  auto i = 5;
  auto j = 2;
  auto sum = 5 + 2;
  writeln(sum);  // prints 7 to console
}

In Java you already need a lot of boiler plate code for this (a 
class for main(), i.e. you have to understand object-orientation 
to begin with!).


If D is too difficult for you, because the tutorials etc. assume 
that you already know how to program (to a certain extent), you 
can either ask people on the forum or try a simpler language 
for which there are very basic tutorials, and come back to D 
later, once you've grasped enough of the concepts that are common 
to all programming languages.


An instantly rewarding language is Lua (lua.org). It was 
designed for people with no programming background, yet it is 
very fast and powerful (it's used in gaming a lot). It has some 
advanced features too (e.g. meta-programming), if you _choose_ to 
use them (it's not a scripting for dummies language).


Personally, I wouldn't recommend an IDE for beginners. It can be 
confusing at times and even worse, it may spoil you as regards 
coding habits. The best way to get familiar with a language or 
coding in general is to use a simple text editor, type everything 
yourself (at the beginning), and soon it will become second 
nature to you. It's like learning an instrument, on the one hand 
you have to practise scales and patterns, and on the other hand 
you have to learn concepts (chords, chord progressions, 
harmonies). In order to be able to grasp the concepts, your brain 
shouldn't be concerned with what your fingers are doing, the 
fingers should move automatically (so that you can listen to 
yourself).


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread ketmar via Digitalmars-d-learn
On Fri, 17 Oct 2014 10:10:09 +0200
spir via Digitalmars-d-learn digitalmars-d-learn@puremagic.com wrote:

 What you say here applies, I guess, to many other points. I applaud
 Ali for writing a tutorial like his but... Check it (just the first
 pages is enough) for literally the dozens of notions one must know
 and master for being able to understand, not only the features of D
 introduced, but even the tutorial itself. If I am not a programmer,
 and one who knows other static langs, and better of the mainstream
 procedural paradigm, if not D itself, then I do not understand more
 than few isolated words here and there. We are blind to the huge pile
 of concepts we know, I guess, because we know them, thus take them
 for granted...
that's why i'm sure that basic programming must be teached in school.
hey, the whole our civilization will collapse without computers!
computer programming is the literacy of the new age.


signature.asc
Description: PGP signature


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread ketmar via Digitalmars-d-learn
On Fri, 17 Oct 2014 04:51:14 +
via Digitalmars-d-learn digitalmars-d-learn@puremagic.com wrote:

 I personally think Logo, Processing and Scheme would be more fun 
 as learning tools, but they are throw-away languages.
yet Scheme will teach how to write functional code. it's a valuable
knowledge for D programmer.


signature.asc
Description: PGP signature


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread ketmar via Digitalmars-d-learn
On Fri, 17 Oct 2014 13:13:36 +
Kagamin via Digitalmars-d-learn digitalmars-d-learn@puremagic.com
wrote:

 In IDE you press F5 and see the program running.
with REPL you typing code, pressing enter and see the code running.


signature.asc
Description: PGP signature


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread Jessica Rauth via Digitalmars-d-learn

On Friday, 17 October 2014 at 08:44:00 UTC, Paulo  Pinto wrote:
On Friday, 17 October 2014 at 01:05:37 UTC, ketmar via 
Digitalmars-d-learn wrote:

On Fri, 17 Oct 2014 00:52:14 +
MachineCode via Digitalmars-d-learn 
digitalmars-d-learn@puremagic.com

wrote:

I don't understand. If at least it were C but java? why not D 
itself?
C is *awful* as beginner's language. never ever let people 
start with

C if you don't hate 'em.

as for D... current version of D can be used, but with some
precautions. we now have excellent book by Ali. (it's great, 
really! i
believe that it must be featured on the front dlang.org page!) 
but java

has alot more books and tutorials.

not that D is bad for beginners, it's just has a smaller 
userbase. and
all that things with classes are reference types and structs 
are not,
empty array is not empty array but is empty array and so on 
D may be
confusing a little. it's good to have some CS background to 
understood

that things.

just my cent and cent.



Better, go with FreePascal http://www.freepascal.org/ and 
discover all that those features that many C advocates spread 
as being close to the machine and other C only features, aren't 
exclusive of it.


Alongside support for real modules, OO and genericity.

Then with a head clean of bad C influences, jump into D.


--
Paulo


One of the problem when starting out with FPC resides in the fact 
that's a completely different family of language (Ada, Pascal, 
Modula vs the C family), syntax and philosophy (for example in 
the RTL).


Another one is that usually people use it in combination with 
Lazarus and as the RAD concept is no shit, people start building 
some applications very fastly. Then when they come to another 
lang. eg D or Cpp they take a big slap in the face. The fact is 
that Obj. Pascal and Delphi often give a wrong appreciation of 
its own skills and abilities.


You talk about genericity but the genericity in Object Pascal is 
currently almost inexistant and doesn't provide a good idea of 
what template-meta-programming is. Actually this looks more 
like a patch to the lang. and some simple things just like 
casting a generic type or global generic functions simply don't 
work at all. While D2 has been written with this idea, FPC will 
never be good with TMP. Even in the commercial version (Delphi 
XE7) they start to add some kind of patchs eg with a compiler 
instrasic which is equivalent to D static if (which means that 
the lang. is not designed for that at all).


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread Jesse Phillips via Digitalmars-d-learn

On Thursday, 16 October 2014 at 22:26:51 UTC, RBfromME wrote:
I'm a newbie to programming and have been looking into the D 
lang as a general purposing language to learn, yet the D 
overview indicates that java would be a better language to 
learn for your first programming language. Why?  Looks like D 
is easier than Java...


The answer is that teaching material for a very beginner is 
limited at the time of that writing we didn't have Ali's book.


http://ddili.org/ders/d.en/

Feel free to give it a try and let the community know things you 
struggled with.


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread eles via Digitalmars-d-learn
On Friday, 17 October 2014 at 13:59:03 UTC, ketmar via 
Digitalmars-d-learn wrote:

On Fri, 17 Oct 2014 10:10:09 +0200
spir via Digitalmars-d-learn 
digitalmars-d-learn@puremagic.com wrote:



computer programming is the literacy of the new age.


Let's say, computer knowledge. There are also database 
administrators, package maintainers, network administrators etc. 
Knowledge of all is useful, not only the knowledge of programmers.


Add builders, engineers, loggers (those with axes) and medics to 
the list...


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread ketmar via Digitalmars-d-learn
On Fri, 17 Oct 2014 14:33:57 +
eles via Digitalmars-d-learn digitalmars-d-learn@puremagic.com wrote:

 On Friday, 17 October 2014 at 13:59:03 UTC, ketmar via 
 Digitalmars-d-learn wrote:
  On Fri, 17 Oct 2014 10:10:09 +0200
  spir via Digitalmars-d-learn 
  digitalmars-d-learn@puremagic.com wrote:
 
  computer programming is the literacy of the new age.
 
 Let's say, computer knowledge.

yes, you are right. that was what i mean: not only programming, but
understanding of how computers works and how to control them.


signature.asc
Description: PGP signature


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread Chris via Digitalmars-d-learn
On Friday, 17 October 2014 at 14:38:39 UTC, ketmar via 
Digitalmars-d-learn wrote:

On Fri, 17 Oct 2014 14:33:57 +
eles via Digitalmars-d-learn 
digitalmars-d-learn@puremagic.com wrote:


On Friday, 17 October 2014 at 13:59:03 UTC, ketmar via 
Digitalmars-d-learn wrote:

 On Fri, 17 Oct 2014 10:10:09 +0200
 spir via Digitalmars-d-learn 
 digitalmars-d-learn@puremagic.com wrote:


 computer programming is the literacy of the new age.

Let's say, computer knowledge.


yes, you are right. that was what i mean: not only programming, 
but

understanding of how computers works and how to control them.


But then people won't trust them bloody machines an inch anymore! 
:-)


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread ketmar via Digitalmars-d-learn
On Fri, 17 Oct 2014 15:40:24 +
Chris via Digitalmars-d-learn digitalmars-d-learn@puremagic.com wrote:

 But then people won't trust them bloody machines an inch anymore! 
 :-)
most people believe that technology is magic. yes, maybe it's too cruel
to ruin their illusions...


signature.asc
Description: PGP signature


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread olivier henley via Digitalmars-d-learn


. D is pristine clean and immensely powerful.

. D is arguably the actual state-of-the-art programming language.

. Ali's book is a gem. Clear, concise and complete. 
http://ddili.org/ders/d.en/


. D is the best investment you can make for your career, right 
now.


. D has Java beans for breakfast. :D


your choice, my two cents.








Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread via Digitalmars-d-learn
On Friday, 17 October 2014 at 14:00:43 UTC, ketmar via 
Digitalmars-d-learn wrote:
yet Scheme will teach how to write functional code. it's a 
valuable knowledge for D programmer.


I think spending a few days with Scheme is valuable for all 
programmers.


By being a minimal language you get down to the essence of 
functional programming by reading some tutorials on Scheme and 
playing with the interpreter.


(and you can more easily configure some open source apps who use 
guile/elisp/scheme, so it has some practical value…)


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread Paulo Pinto via Digitalmars-d-learn

Am 17.10.2014 um 16:14 schrieb Jessica Rauth:

On Friday, 17 October 2014 at 08:44:00 UTC, Paulo  Pinto wrote:

On Friday, 17 October 2014 at 01:05:37 UTC, ketmar via
Digitalmars-d-learn wrote:

On Fri, 17 Oct 2014 00:52:14 +
MachineCode via Digitalmars-d-learn digitalmars-d-learn@puremagic.com
wrote:


I don't understand. If at least it were C but java? why not D itself?

C is *awful* as beginner's language. never ever let people start with
C if you don't hate 'em.

as for D... current version of D can be used, but with some
precautions. we now have excellent book by Ali. (it's great, really! i
believe that it must be featured on the front dlang.org page!) but java
has alot more books and tutorials.

not that D is bad for beginners, it's just has a smaller userbase. and
all that things with classes are reference types and structs are not,
empty array is not empty array but is empty array and so on D may be
confusing a little. it's good to have some CS background to understood
that things.

just my cent and cent.



Better, go with FreePascal http://www.freepascal.org/ and discover all
that those features that many C advocates spread as being close to the
machine and other C only features, aren't exclusive of it.

Alongside support for real modules, OO and genericity.

Then with a head clean of bad C influences, jump into D.


--
Paulo


One of the problem when starting out with FPC resides in the fact that's
a completely different family of language (Ada, Pascal, Modula vs the C
family), syntax and philosophy (for example in the RTL).

Another one is that usually people use it in combination with Lazarus
and as the RAD concept is no shit, people start building some
applications very fastly. Then when they come to another lang. eg D or
Cpp they take a big slap in the face. The fact is that Obj. Pascal and
Delphi often give a wrong appreciation of its own skills and abilities.



Although I am biased to the Pascal family of languages, this has been 
done in real world for a couple of decades.


When I joined the New University of Lisbon as a student in 1994, I was 
lucky that the professor heading the programming languages section, had 
a similar opinion as me in terms of programming languages.


The first year students had introduction to programming with P2C/GNU 
Pascal in the first semester, followed by C++ with gcc in the second 
semester.


There was no C, at all. It was expected that any student compent enough 
to use C++, would be able to code in straight C if asked to do so.


On my last year at the university (1998/9), I one of the teachers giving 
those lab classes to students. By then, we were using Delphi and Visual 
C++ instead.


The students didn't had much problems switching languages.

They got to learn that using pointers doesn't need to be the dragon that 
C makes out to be.


That there was a way to deal with strings, arrays and reference 
parameters without impact in the whole application. The most curious got 
to learn how to disable bounds checking.


They learned how to write modular applications without having to prefix 
all their identifiers.


They also learned that C wasn't the only way to touch the machine at all 
levels.






You talk about genericity but the genericity in Object Pascal is
currently almost inexistant and doesn't provide a good idea of what
template-meta-programming is. Actually this looks more like a patch to
the lang. and some simple things just like casting a generic type or
global generic functions simply don't work at all. While D2 has been
written with this idea, FPC will never be good with TMP. Even in the
commercial version (Delphi XE7) they start to add some kind of patchs eg
with a compiler instrasic which is equivalent to D static if (which
means that the lang. is not designed for that at all).



I just referenced it, because I saw it mentioned a few times in Delphi 
documentation, but never came to use it.


Since 2000 that I don't do anything in the Pascal world of languages, 
besides collecting Oberon related stuff.


--
Paulo


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread Joakim via Digitalmars-d-learn
On Friday, 17 October 2014 at 13:59:03 UTC, ketmar via 
Digitalmars-d-learn wrote:
that's why i'm sure that basic programming must be teached in 
school.

hey, the whole our civilization will collapse without computers!
computer programming is the literacy of the new age.


This is nonsense and I see it repeated all the time, with 
code.org and other efforts.  Do you know how to fix your car, 
washing machine, or refrigerator?  No, yet your life would likely 
collapse far faster without those.  You hire somebody to do the 
job if any of those mechanical systems breaks.  Similarly, most 
people hire programmers to do the software work they don't want 
to do.


I will agree that basic computer literacy is important, ie people 
should know their way around a computer or tablet, how to open 
and turn off apps, mouse or touch your way around the UI, etc.  
But beyond that it's a matter of interest: some people like 
Walter want to work on their car or computer, but most people 
don't.


On Friday, 17 October 2014 at 14:00:43 UTC, ketmar via 
Digitalmars-d-learn wrote:
yet Scheme will teach how to write functional code. it's a 
valuable

knowledge for D programmer.


My first programming language was Scheme in my freshman year of 
college (I wasn't one of those kids programming since middle 
school).  Scheme was fine for the time, though the scads of 
parentheses were annoying, but I think we can do better decades 
later.  D would work fine if it's presented at a level 
appropriate to a beginner, ie not assuming they know anything 
about programming to begin with.


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread ketmar via Digitalmars-d-learn
On Fri, 17 Oct 2014 20:40:37 +
Joakim via Digitalmars-d-learn digitalmars-d-learn@puremagic.com
wrote:

 On Friday, 17 October 2014 at 13:59:03 UTC, ketmar via 
 Digitalmars-d-learn wrote:
  that's why i'm sure that basic programming must be teached in 
  school.
  hey, the whole our civilization will collapse without computers!
  computer programming is the literacy of the new age.
 
 This is nonsense and I see it repeated all the time, with 
 code.org and other efforts.  Do you know how to fix your car, 
 washing machine, or refrigerator?
i have no car, i know how to fix my wahing machine, i know how to fix
my refrigerator.

 No, yet your life would likely collapse far faster without those.
my life is not the whole human civilization.

 You hire somebody to do the 
 job if any of those mechanical systems breaks.  Similarly, most 
 people hire programmers to do the software work they don't want 
 to do.
...and pretty sure that computers are magical devices. oh, how many
times i've seen people doing tedious repetetive work for hours, that
kind of work that can be done in seconds by the simple script.

actually, that's why people so love their pads: no-brain-required.
not only that, but no easy way to made it do what i want too. i still
can't understant that kind of attitude.

 I will agree that basic computer literacy is important, ie people 
 should know their way around a computer or tablet, how to open 
 and turn off apps, mouse or touch your way around the UI, etc.  
 But beyond that it's a matter of interest: some people like 
 Walter want to work on their car or computer, but most people 
 don't.
inability to write a simple script to automate some task is not
different from inability to write some words on a piece of paper.
yet i see how the argument oh, well, i hire someone to write that for
me fits here.


signature.asc
Description: PGP signature


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread Joakim via Digitalmars-d-learn
On Friday, 17 October 2014 at 21:20:29 UTC, ketmar via 
Digitalmars-d-learn wrote:

On Fri, 17 Oct 2014 20:40:37 +
Joakim via Digitalmars-d-learn 
digitalmars-d-learn@puremagic.com

wrote:
This is nonsense and I see it repeated all the time, with 
code.org and other efforts.  Do you know how to fix your car, 
washing machine, or refrigerator?
i have no car, i know how to fix my wahing machine, i know how 
to fix

my refrigerator.


You do realize that most people are clueless about how to fix 
those also, right?  Would you require that how to fix all that 
mechanical stuff be taught in schools too?  Kids would never 
leave school if they had to learn all the stuff everybody says 
they should be forced to learn. ;)


No, yet your life would likely collapse far faster without 
those.

my life is not the whole human civilization.


Yet, civilization is made up of people like you, who would all 
miss those mechanical systems far more than computers.


You hire somebody to do the job if any of those mechanical 
systems breaks.  Similarly, most people hire programmers to do 
the software work they don't want to do.
...and pretty sure that computers are magical devices. oh, how 
many
times i've seen people doing tedious repetetive work for hours, 
that

kind of work that can be done in seconds by the simple script.


They should use tools like Automator instead, no programming 
needed:


http://en.wikipedia.org/wiki/Automator_(software)

actually, that's why people so love their pads: 
no-brain-required.
not only that, but no easy way to made it do what i want too. 
i still

can't understant that kind of attitude.


Tablets are optimized for basic usage, not saving files and 
document editing and whatever else you might want to do on a PC.  
Most people just need a basic appliance that isn't going to catch 
viruses or require registry hacks.


I will agree that basic computer literacy is important, ie 
people should know their way around a computer or tablet, how 
to open and turn off apps, mouse or touch your way around the 
UI, etc.  But beyond that it's a matter of interest: some 
people like Walter want to work on their car or computer, but 
most people don't.

inability to write a simple script to automate some task is not
different from inability to write some words on a piece of 
paper.


It is completely different, because there are tools like 
Automator to help you automate your workflow without needing to 
write anything.  If you need to communicate something on paper- 
well, nobody uses paper these days so let's say in text ;) - 
that's more basic and fundamental.


yet i see how the argument oh, well, i hire someone to write 
that for

me fits here.


For most people, that is a better route, particularly if they 
don't need to modify the script as they go and just need it 
written once.


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread ketmar via Digitalmars-d-learn
On Fri, 17 Oct 2014 23:31:45 +
Joakim via Digitalmars-d-learn digitalmars-d-learn@puremagic.com
wrote:

 You do realize that most people are clueless about how to fix 
 those also, right?
most people are stupid.

 Would you require that how to fix all that 
 mechanical stuff be taught in schools too?
but it is! or at least it was. it's all simple physics, you know. not a
rocket science.

 Kids would never 
 leave school if they had to learn all the stuff everybody says 
 they should be forced to learn. ;)
nobody should be *forced* to learn: it's pointless. yet kids are very
curious, and they can be taught *alot* of things if they think that
they are just playing. make it interesting, and you'll be amazed how
much kids can learn almost without problems.

 Yet, civilization is made up of people like you, who would all 
 miss those mechanical systems far more than computers.
it's a huge difference between i miss my washing machine and all our
communication and data processing systems are foobared.

 They should use tools like Automator instead, no programming 
 needed:
 
 http://en.wikipedia.org/wiki/Automator_(software)
i wasn't talking about sorting out file mess. i was talking about
tabular data processing, for example, with some logics and calculations
that can't be done automatically without programming.

 Tablets are optimized for basic usage
what is basic usage? i really don't know what tablets are for. what i
can do with it? watching movie? listening music? reading book? yes,
tablets can do this... badly. what else?

i can listen music with my N900, and it fits in my pocket.

movies? on tablet screen? no, thanks.

books? electronic books are better.

tablets are like XML: bad for everything.

 Most people just need a basic appliance that isn't going to catch 
 viruses or require registry hacks.
give 'em wooden board with painting. it's great!

 It is completely different, because there are tools like 
 Automator to help you automate your workflow without needing to 
 write anything.
oh, please. i can do batch renaming with wildcards, and for any
task that is more complex than that there *is* a need to write
logic. scripts. graphic programming is a dead end. people drop icons
in favor of alphabet 'cause alphabet is just better.

 If you need to communicate something on paper- 
 well, nobody uses paper these days
i wish that the goverment of my country knows about that. and banking.
somehow they still insist to have everything written on paper.

 For most people, that is a better route, particularly if they 
 don't need to modify the script as they go and just need it 
 written once.
so instead of spending ten minutes to write the script they'll spend a
day searching for someone to hire and pay him money. great. thanks to
such people we have don't put your pet into microwave-like
instructions. and that instructions are pointless 'cause such people
never reads any instructions anyway.

most people are stupid, but that's not what scares me alot. what really
scare me is that most people *love* to be stupid and fight for the
right to be stupid with passion.

p.s. me too. i can't force myself to take English courses for five
damned years!


signature.asc
Description: PGP signature


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread ketmar via Digitalmars-d-learn
On Sat, 18 Oct 2014 03:05:58 +0300
ketmar via Digitalmars-d-learn digitalmars-d-learn@puremagic.com
wrote:

p.p.s. just in case: i'm not talking about personalities here, sorry if
i was offencive.


signature.asc
Description: PGP signature


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread RBfromME via Digitalmars-d-learn

On Thursday, 16 October 2014 at 22:26:51 UTC, RBfromME wrote:
I'm a newbie to programming and have been looking into the D 
lang as a general purposing language to learn, yet the D 
overview indicates that java would be a better language to 
learn for your first programming language. Why?  Looks like D 
is easier than Java...


Thank you for taking the time to respond to my inquiry.  I've 
been reading up on different languages for some time now. I have 
experimented with python some and have  created a few minor 
scripts. It's fairly easy to get going with the basics , but i 
don't find the basics any easier to  learn than D's.  The biggest 
issue i personal find in getting deeper into  a language is the 
docs and examples. The python examples, beyond the basics usually 
get write into OO so you find your self trying to figure out OO 
while trying to sift through the examples.  Makes it a little 
harder to get going and figure out the available libraries while 
trying to figure OO at the same time.
The second thing that would help a beginner move forward is the 
documentation  on the libraries. I see D has  standard libraries 
along with third parties. And I believe , if i read it properly, 
D can us C libraries. It would be helpful to see examples on how 
to use C libs with D since D is still new and its library 
packages is still small.
Summing it up, I personally think the hardest part in learning to 
use a specific language is the docs and and examples because they 
all throw you write into OO and you spend more time trying to 
figure out OO instead of how to use the standard lib or third 
party lib to get a basic task done.


Thank you Ali Cehreli for taking the time to write the D 
tutorial. It's appreciated by people like me.


Re: Beginner ?. Why does D suggest to learn java

2014-10-17 Thread Rikki Cattermole via Digitalmars-d-learn

On 18/10/2014 3:00 p.m., RBfromME wrote:

On Thursday, 16 October 2014 at 22:26:51 UTC, RBfromME wrote:

I'm a newbie to programming and have been looking into the D lang as a
general purposing language to learn, yet the D overview indicates that
java would be a better language to learn for your first programming
language. Why?  Looks like D is easier than Java...


Thank you for taking the time to respond to my inquiry.  I've been
reading up on different languages for some time now. I have experimented
with python some and have  created a few minor scripts. It's fairly easy
to get going with the basics , but i don't find the basics any easier
to  learn than D's.  The biggest issue i personal find in getting deeper
into  a language is the docs and examples. The python examples, beyond
the basics usually get write into OO so you find your self trying to
figure out OO while trying to sift through the examples.  Makes it a
little harder to get going and figure out the available libraries while
trying to figure OO at the same time.
The second thing that would help a beginner move forward is the
documentation  on the libraries. I see D has  standard libraries along
with third parties. And I believe , if i read it properly, D can us C
libraries. It would be helpful to see examples on how to use C libs with
D since D is still new and its library packages is still small.


If you want to see shared libraries with a c interface bound to D 
DerelictOrg is a great place to look[0].



Summing it up, I personally think the hardest part in learning to use a
specific language is the docs and and examples because they all throw
you write into OO and you spend more time trying to figure out OO
instead of how to use the standard lib or third party lib to get a basic
task done.


I and I'm sure others, will be happy to talk with you about any concepts 
and ideas that you have trouble understanding. Just let us know.



Thank you Ali Cehreli for taking the time to write the D tutorial. It's
appreciated by people like me.


[0] https://github.com/DerelictOrg


Beginner ?. Why does D suggest to learn java

2014-10-16 Thread RBfromME via Digitalmars-d-learn
I'm a newbie to programming and have been looking into the D lang 
as a general purposing language to learn, yet the D overview 
indicates that java would be a better language to learn for your 
first programming language. Why?  Looks like D is easier than 
Java...


Re: Beginner ?. Why does D suggest to learn java

2014-10-16 Thread Ali Çehreli via Digitalmars-d-learn

On 10/16/2014 03:26 PM, RBfromME wrote:

 I'm a newbie to programming and have been looking into the D lang as a
 general purposing language to learn, yet the D overview indicates that
 java would be a better language to learn for your first programming
 language. Why?  Looks like D is easier than Java...

Here:

  http://dlang.org/overview.html

As a first programming language - Basic or Java is more suitable for 
beginners.


I say, just ignore that comment. :) We should open a bug report for that 
page.


I had great fun writing a programming book for complete beginners and 
found it very easy to use D for that purpose:


  http://ddili.org/ders/d.en/

Ali



Re: Beginner ?. Why does D suggest to learn java

2014-10-16 Thread Brad Anderson via Digitalmars-d-learn

On Thursday, 16 October 2014 at 22:26:51 UTC, RBfromME wrote:
I'm a newbie to programming and have been looking into the D 
lang as a general purposing language to learn, yet the D 
overview indicates that java would be a better language to 
learn for your first programming language. Why?  Looks like D 
is easier than Java...


The Overview page is ancient and needs to be rewritten. The 
included example sieve program reflects this. It's almost C 
(you'd only need to make minor changes to 4 of the lines to make 
it build with gcc). I'd agree that C probably isn't a good first 
language. The overview also suggests learning BASIC first which 
also shows just how old the Overview is (where do you even get a 
BASIC compiler these days?).


There are easier languages but modern, idiomatic D is perfectly 
approachable for beginners in my opinion.


https://issues.dlang.org/show_bug.cgi?id=13624


Re: Beginner ?. Why does D suggest to learn java

2014-10-16 Thread ketmar via Digitalmars-d-learn
On Thu, 16 Oct 2014 22:43:11 +
Brad Anderson via Digitalmars-d-learn
digitalmars-d-learn@puremagic.com wrote:

 also shows just how old the Overview is (where do you even get a 
 BASIC compiler these days?).
voila: http://www.freebasic.net/
;-)


signature.asc
Description: PGP signature


Re: Beginner ?. Why does D suggest to learn java

2014-10-16 Thread MachineCode via Digitalmars-d-learn

On Thursday, 16 October 2014 at 22:42:21 UTC, Ali Çehreli wrote:

On 10/16/2014 03:26 PM, RBfromME wrote:

 I'm a newbie to programming and have been looking into the D
lang as a
 general purposing language to learn, yet the D overview
indicates that
 java would be a better language to learn for your first
programming
 language. Why?  Looks like D is easier than Java...

Here:

  http://dlang.org/overview.html

As a first programming language - Basic or Java is more 
suitable for beginners.


I say, just ignore that comment. :) We should open a bug report 
for that page.


I had great fun writing a programming book for complete 
beginners and found it very easy to use D for that purpose:


  http://ddili.org/ders/d.en/

Ali


I don't understand. If at least it were C but java? why not D 
itself?


Re: Beginner ?. Why does D suggest to learn java

2014-10-16 Thread ketmar via Digitalmars-d-learn
On Fri, 17 Oct 2014 00:52:14 +
MachineCode via Digitalmars-d-learn digitalmars-d-learn@puremagic.com
wrote:

 I don't understand. If at least it were C but java? why not D 
 itself?
C is *awful* as beginner's language. never ever let people start with
C if you don't hate 'em.

as for D... current version of D can be used, but with some
precautions. we now have excellent book by Ali. (it's great, really! i
believe that it must be featured on the front dlang.org page!) but java
has alot more books and tutorials.

not that D is bad for beginners, it's just has a smaller userbase. and
all that things with classes are reference types and structs are not,
empty array is not empty array but is empty array and so on D may be
confusing a little. it's good to have some CS background to understood
that things.

just my cent and cent.


signature.asc
Description: PGP signature


Re: Beginner ?. Why does D suggest to learn java

2014-10-16 Thread bearophile via Digitalmars-d-learn

RBfromME:

I'm a newbie to programming and have been looking into the D 
lang as a general purposing language to learn, yet the D 
overview indicates that java would be a better language to 
learn for your first programming language. Why?  Looks like D 
is easier than Java...


Python is probably a better first language than Java. D is a
little too much complex as first language.

Bye,
bearophile


Re: Beginner ?. Why does D suggest to learn java

2014-10-16 Thread via Digitalmars-d-learn

On Friday, 17 October 2014 at 01:14:34 UTC, bearophile wrote:

Python is probably a better first language than Java. D is a
little too much complex as first language.


The IDE support is probably a bit better with Java/C# and using a 
statically typed language as your first language has advantages, 
but all are good first languages: easy to find tutorials, easy to 
find educational example code, easy to find answers to typical 
beginner issues on Stackoverflow…


I personally think Logo, Processing and Scheme would be more fun 
as learning tools, but they are throw-away languages. E.g. 
http://turtleacademy.com/programs/en http://www.processing.org/ 
and many more online programming sites.





Re: Beginner ?. Why does D suggest to learn java

2014-10-16 Thread maarten van damme via Digitalmars-d-learn
While d can be complex, there's nothing preventing you from starting out
simple and not using all features at first.
I don't understand why it's not suitable for a beginner if you use this
approach...

2014-10-17 6:51 GMT+02:00 via Digitalmars-d-learn 
digitalmars-d-learn@puremagic.com:

 On Friday, 17 October 2014 at 01:14:34 UTC, bearophile wrote:

 Python is probably a better first language than Java. D is a
 little too much complex as first language.


 The IDE support is probably a bit better with Java/C# and using a
 statically typed language as your first language has advantages, but all
 are good first languages: easy to find tutorials, easy to find educational
 example code, easy to find answers to typical beginner issues on
 Stackoverflow…

 I personally think Logo, Processing and Scheme would be more fun as
 learning tools, but they are throw-away languages. E.g.
 http://turtleacademy.com/programs/en http://www.processing.org/ and many
 more online programming sites.