Re: Prog. Languages (was: question?)

2001-06-01 Thread Romain Lerallut
--- Wayne Sitton [EMAIL PROTECTED]
 wrote:
...
My question is what programming language is best to learn??

Wayne


Usually, you choose a language depending on what you want done. YMMV.

If you want to learn a bit about computer languages
*in general* you may want to:

1) start with interpreted languages, such as Perl. ( not Python which is 
strongly object-oriented). It's easy to create a proglet that is useful , and 
very satisfying.


2a) then learn about object-oriented languages (Java, Python). I would advise 
*against* starting with an OO language, since it *might* be harder to come back 
to
non-OO languages.

*OR*

2b) then learn about compiled languages such as C. C is harder to program than 
interpreted languages, mostly because of memory management issues, but it is 
also IMHO very elegantly written.
 It has a lot of balance in its conception. You can understand more of the 
internals with C than with Java.
*After* being decently fluent in C, you may want to learn C++ or others. Though 
I like C better for its simplicity and elegance.

3) then learn advanced Object-Oriented programming
4) or then learn highly abstracted languages such as Lisp or Objective CaML. 
Very good stuff there, but rather abstract I'm afraid. This is a special realm, 
be warned. :)
5) re-code KDE in assembly language. 


These are my opinions, based on my experiences with those languages (assembler 
and Python exepted), and my own tastes. Others may have different opinions, but 
PLEASE this is NOT a troll comparing the respective merits of different 
languages.


Just don't use Fortran !! 
( I do enough of it for both of us and a lot left over)

HTH,
Romain

_
Sign up for FREE email from the Official Site for Garfield and Friends. Just go 
to http://www.e-garfield.com



Re: Prog. Languages (was: question?)

2001-06-01 Thread Erik Steffl
Romain Lerallut wrote:
...
 Usually, you choose a language depending on what you want done. YMMV.

  yes, that's most important - depending on what you will do/what
interests you, choose appropriate language...

  in general, go for design/analysis not for particular language -
programming is fairly abstract science/art/magic...

 1) start with interpreted languages, such as Perl. ( not Python which is 
 strongly object-oriented). It's easy to create a proglet that is useful , and 
 very satisfying.
 
 2a) then learn about object-oriented languages (Java, Python). I would advise 
 *against* starting with an OO language, since it *might* be harder to come 
 back to
 non-OO languages.

  I'd say it's the other way around - learn OO first and use it, even if
the language does not support it. never go back to straight structural
programming...

 2b) then learn about compiled languages such as C. C is harder to program 
 than interpreted languages, mostly because of memory management issues, but 
 it is also IMHO very elegantly written.

  learn C++ where you don't have to deal with memory that much and you
have lot of fairly convenient data types/structures/containers that take
care of themselves (strings, arrays etc.)

  you might also try java but I find it quite simplistic and messy (just
learning it so my opinion is not very authoritative)

erik



Re: Prog. Languages (was: question?)

2001-06-01 Thread D-Man
On Fri, Jun 01, 2001 at 02:13:20AM -0700, Romain Lerallut wrote:
| --- Wayne Sitton [EMAIL PROTECTED] wrote:
| 
| My question is what programming language is best to learn??
| 
| Usually, you choose a language depending on what you want done. YMMV.

Ditto.

| If you want to learn a bit about computer languages *in general* you
| may want to:
| 
| 1) start with interpreted languages, 

Ditto

| such as Perl. ( not Python which is strongly object-oriented). It's
| easy to create a proglet that is useful , and very satisfying.

I disagree here.  Python is strongly object-oriented, but you don't
have to know you are dealling with objects until you are ready to
leanr about classes.  You can write programs that only use functions
and built-in types in traditional Perl style.  I feel that Perl is too
complicated and tricky to keep track of all the slight variations of
the punctuation that have very different meanings.  I saw this quote one
time that I found to be funny, and rather accurate :

~~~
Python is executable pseudocode. Perl is executable line noise.
~~~

| 2a) then learn about object-oriented languages (Java, Python). I
| would advise *against* starting with an OO language, since it
| *might* be harder to come back to non-OO languages.

I started with OO (Eiffel, then C++ and Java, then C,  I learned
Python on my own in the middle,  then a little Common Lisp and Perl)
This is the order of the courses at my school.

I agree with Romain that once you get in the habit of OO (good
encapsulation and polymorphism) it is very hard not to use it.  I
don't think that is a bad thing either -- OO is a nice way to design
an easier to maintain and extend system.  For example even though C is
not naturally OO the GTK+ developers used a strongly OO style which
makes GTK as easy to learn as any other toolkit (such as Qt or Swing).
Constrast that with XForms shudder.

| *OR*
| 
| 2b) then learn about compiled languages such as C. C is harder to
| program than interpreted languages, mostly because of memory
| management issues, but it is also IMHO very elegantly written.
| 
| It has a lot of balance in its conception. You can understand more
| of the internals with C than with Java.
| 
| *After* being decently fluent in C, you may want to learn C++ or
| others. Though I like C better for its simplicity and elegance.

C is nice and simple and well suited for lower level task.  It was
originally designed as a systems programming language, not an
applications programming language. 

If you learn C/C++ or Java after learning Python you can use them to
enhance Python.

| 4) or then learn highly abstracted languages such as Lisp or
| Objective CaML. Very good stuff there, but rather abstract I'm
| afraid. This is a special realm, be warned. :)

They are interesting.  Maybe add Prolog and Haskell to the list?  I
don't know too much in this area, but I got an intro to Common Lisp
and Scheme while getting an intro to Functional Programming in a class.

| 5) re-code KDE in assembly language. 

Hah, there goes your portability ;-).  That's fine by me since I like
GNOME anyways :-).  See the steps below -- notably 1 and 3.

| These are my opinions, based on my experiences with those languages
| (assembler and Python exepted), and my own tastes. Others may have
| different opinions, but PLEASE this is NOT a troll comparing the
| respective merits of different languages.

Ditto (except that I have used Python and M68k Assembly,  Python is my
favorite language).

| Just don't use Fortran !! 
| 
| ( I do enough of it for both of us and a lot left over)

:-).  I have heard that Fortran can be quite painful in the cranial
area ...  


A good practice of programming invovles the following steps :

o  code in a high-level language that allows for RAD development
(RAD == Rapid Application Development)

o  profile the app to see where most of the time is spent,  80% of
   the execution time is spent in 20% of the code and it is
   usually not the code you expect

o  recheck your algorithm to be sure you are using the best one,
   use a different one if necessary

o  iff the app is still too slow recode the _portions_ that are
   bottlenecks in a lower level language to improve the speed

Python is excellent (IMNSHO) for the first 3 steps, and C, C++ and
Java work very well with Python for the last step.


I think that Python is an excellent first language, and depending on
your needs, could be the only one you need.  It is still beneficial to
study other languages and understand the tradeoffs involved with the
different combinations of features.

Another thing to learn:   if you plan on writing large applications
and maintaining them over some period of time, design is much more
important than the language you implement it in.  If you only want to
tinker with some 

Re: Prog. Languages (was: question?)

2001-06-01 Thread Bruce Sass
On Fri, 1 Jun 2001, Romain Lerallut wrote:
 Usually, you choose a language depending on what you want done. YMMV.

 If you want to learn a bit about computer languages
 *in general* you may want to:

 1) start with interpreted languages, such as Perl. ( not Python
which is strongly object-oriented). It's easy to create a proglet
that is useful , and very satisfying.

This would be a mistake.

Perl code can be hard to read and the language itself is biased
towards text processing (Practical Extracting and Reporting Language;
Python is a general purpose language with clear syntax and semantics,
just what a beginner needs.

 2a) then learn about object-oriented languages (Java, Python). I
would advise *against* starting with an OO language, since it *might*
be harder to come back to
 non-OO languages.

Python does not require you to use obviously OO techniques (classes,
etc.) for everything, you can write in pretty much any style you like.

 *OR*

 2b) then learn about compiled languages such as C. C is harder to
program than interpreted languages, mostly because of memory
management issues, but it is also IMHO very elegantly written.
  It has a lot of balance in its conception. You can understand more
of the internals with C than with Java.
 *After* being decently fluent in C, you may want to learn C++ or
others. Though I like C better for its simplicity and elegance.

Sure, if you want to learn about computer internals also (hard to get
away from that with a low level language like C)... I think it is the
best way to start.  Steep learning curve, though.


- Bruce