LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 03-04-2007, 12:29 PM   #1
seimour
LQ Newbie
 
Registered: Feb 2006
Location: Euroland
Distribution: Debian Stable
Posts: 26

Rep: Reputation: 15
Which of theese three to begin with? C++/Python/Ruby


Hi there folks! I'd like to know between those three which might be the best option to begin with. I'd programmed before on C, but it was long ago and I didn't remember most of it, just notions. I also learned some VB, Java and PLSQL, but I don't remember a single thing of them neither I want to hear of them. I'd just like to learn either C++, Python or Ruby.

x Python may be the easiest for the beginning and it can be useful for sripting on Linux, The Gimp or Blender.
x Ruby. Well I'm more interested on ruby on rails but it would be great to know the internals too.
x C++. This one can be the best out there (I dislike Java) if performance/speed is the point. I've always been interested on learning it, but it ain't as easiest as the other two.

I'm currently using Arch and I don't plan to turn back to windows ever, but at least portability is an interesting point and the three of them follow that, as far I'm concerned. So which might be the best to jump into programming without having been in contact for a long time, say 5 years?

BTW, for C++ how good is this book? May I trust amazon users' reviews?

Thanks in advance. Sorry, large post :P
 
Old 03-04-2007, 12:59 PM   #2
iamnothere
Member
 
Registered: Feb 2007
Location: UK
Distribution: Slamd 64, Slackware
Posts: 46

Rep: Reputation: 16
Why "either"? Programming languages are not mutually exclusive. You need to learn several, depending on what sort or programming you want to do. First, you might want to brush up on your C, since the vast majority of Linux software is written in C. And learn at least one "scripting" language, my preference is Python, but since they are all free, you can dabble with perl/python/ruby/etc and see which one you prefer. There is no "perfect" language that is suitable for everything. Also, if you don't know shell scripting already, then learn that first; shell scripting is _essential_ on a unix system for chaining tools together. Having said that though, you should almost certainly learn the basics of Python, it's extremely easy to learn, more importantly it's easy to _read_, unlike a certain other language that starts with P!

Last edited by iamnothere; 03-04-2007 at 01:02 PM.
 
Old 03-04-2007, 01:08 PM   #3
vargadanis
Member
 
Registered: Sep 2006
Posts: 248

Rep: Reputation: 30
Me personally would choose Perl first. Perl is pretty impressive in every way. The syntax is very similar to the syntax of C, C++. Perl is faster than python or ruby. I experienced Ruby to be the slowest but the most OO. In Ruby everything is an object that make the people's life easier. In Ruby, you can write such programs in 5 minutes that you have never thought about in Perl or C++. Also Ruby is one of the most dynamically growing and extending language nowadays. Esp. on the east (Japan, China).
I love how well built is Ruby and I love the performance of Perl. If you want an OO language and the speed does not matter: Ruby. If you want a quickly interpreted non-OO language (by default) Perl can be a good choice. (However PHP is also a good choice as you can do mostly everything with it, even GUI [TK, WxWidgets, Gtk1, Gtk2]).
 
Old 03-04-2007, 01:12 PM   #4
Proud
Senior Member
 
Registered: Dec 2002
Location: England
Distribution: Used to use Mandrake/Mandriva
Posts: 2,794

Rep: Reputation: 116Reputation: 116
I'll say that I really enjoyed learning Python a few years back, but atm I'm loving the new features in Java. Learning a diverse mix is good, check out Haskell if you want to try Functional programming (imagine life without persistent variables, where recursion is god).
 
Old 03-04-2007, 01:23 PM   #5
bigearsbilly
Senior Member
 
Registered: Mar 2004
Location: england
Distribution: Mint, Armbian, NetBSD, Puppy, Raspbian
Posts: 3,515

Rep: Reputation: 239Reputation: 239Reputation: 239
It depends on what you want to do?


IMHO C++ is horrible. C is neat and concise.
python is lovely to use, perl is on most unix machines, it's fast and gives a great ride - but it's a bit ugly to look at the next day.

then there's the queen of languages, lisp
 
Old 03-04-2007, 04:03 PM   #6
taylor_venable
Member
 
Registered: Jun 2005
Location: Indiana, USA
Distribution: OpenBSD, Ubuntu
Posts: 892

Rep: Reputation: 43
@Proud It's so awesome that you mention Haskell -- a fantastic language that I've not seen mentioned by anyone else but me on these forums. Kudos to you, good sir (or madam)!

@seimour Going along (somewhat) with what bigearsbilly said, Scheme is a great learning language; it'll teach you a lot about how programs work from a theoretical standpoint. Plus with R6RS coming out soon (hopefully) there's even more to be excited about.

But if you want to decide between C++, Python, and Ruby -- I'd say learn C++ and Ruby first. They fall in somewhat different realms of programming, whereas Python lies fairly close to Ruby. So learn those two first, and then Python later. Of course, always keep learning as many lanuages as you can to improve all your skills as a programmer.

One other important thing to learn about programming is an editor. Pick one up and learn it completely. I recommend GNU Emacs if you're not already wedded to another. Learning Emacs has the added benefit of forcing you to learn Lisp to do really cool fancy things. So you can kill two birds with one stone!
 
Old 03-04-2007, 04:22 PM   #7
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682
If you want to write programs using the KDE or Gnome frameworks, then C++. If you are very interested in Blender, Python. Maybe Ruby on Rails has got your fancy. Fortunately, the skills and principles of one language can apply to another.
Perl does have a large community around it. There are people who don't like perl but choose it because of all of the packages available on CPAN.

Last edited by jschiwal; 03-07-2007 at 02:56 PM.
 
Old 03-04-2007, 11:21 PM   #8
taylor_venable
Member
 
Registered: Jun 2005
Location: Indiana, USA
Distribution: OpenBSD, Ubuntu
Posts: 892

Rep: Reputation: 43
s/CTAN/CPAN/ -> CTAN is for TeX
 
Old 03-05-2007, 02:56 AM   #9
seimour
LQ Newbie
 
Registered: Feb 2006
Location: Euroland
Distribution: Debian Stable
Posts: 26

Original Poster
Rep: Reputation: 15
Ok.

Thanks everyone for giving me their own points of view. As iamnothere said, I'll begin with shell scripting which I haven't used/studied for ages. I got a nice book about it called Linux commands, editors and shell programming which I haven't started reading yet. I'd also want to learn a language that let me do more sophisticated things (rather that scripts) like GUIs, DBs, Internet, server-client, etc and for those things I think C/C++ is the de facto. Python/Ruby can be useful to extend shell scripting.

And for getting a good job? I'm not interested on doing this for a living but as a hobby. I rather prefer to work as a system admin than beeing a programmer the rest of my life. This is my point of view, not to offend anyone.

Well, I guess I'll begin with shell scripting which is the first step. Cheers!

PS, Isn't Perl more tedious than Python/Ruby ?

Last edited by seimour; 03-05-2007 at 02:59 AM.
 
Old 03-05-2007, 03:09 AM   #10
bigearsbilly
Senior Member
 
Registered: Mar 2004
Location: england
Distribution: Mint, Armbian, NetBSD, Puppy, Raspbian
Posts: 3,515

Rep: Reputation: 239Reputation: 239Reputation: 239
perl is not tedious it is fun, sometimes infuriating
but undeniably powerful.

The beauty of perl is you can do just about anything with it you can do in C.

as for sysadmin, C/C++ is of little use but perl is VERY useful.
python is not installed on most prodcution environments by default (unfortunately
as I'd love to get to know it better).
 
Old 03-05-2007, 02:59 PM   #11
uselpa
Senior Member
 
Registered: Oct 2004
Location: Luxemburg
Distribution: Slackware, OS X
Posts: 1,507

Rep: Reputation: 47
Personally I'd suggest Python. It can also do GUIs, DBs, Internet, server-client, it's not a classical "scripting language". And it is great fun, too.
 
Old 03-07-2007, 02:57 PM   #12
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682
Quote:
Originally Posted by taylor_venable
s/CTAN/CPAN/ -> CTAN is for TeX
Thank you for the correction. I was thinking of both when I typed it. I edited my original post.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Perl vs. Ruby vs. Python vargadanis Programming 53 12-31-2010 12:37 PM
PHP v Ruby/Ruby on Rails Neko_D Linux - General 4 02-08-2007 11:56 PM
[Ruby] Tar'ing or Zip'ing with ruby script lmcilwain Programming 2 01-19-2007 06:56 PM
What does theese installing error messages mean? Harp00 Slackware 2 04-25-2004 04:25 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 08:28 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration