Thursday, July 30, 2009

Which programming language should I learn next: Perl or C/C++?

I have O'Reilly books for learning both. I currently program in mainly VB5 and have done a smattering of assembly. I've DLed %26amp; installed the free express editions of VB 2005 and VC++ 2005 from MS, and also the Open Perl IDE. I also have Bloodshed Dev C++, Codeblocks, and WinAsm Studio. (I've been casting about for some good programming environments.)





Any suggestions?

Which programming language should I learn next: Perl or C/C++?
It depends what you want to do. Is this for a purpose or purely academic.





If it's academic, flip a coin.





If you have a purpose in mind, that will weigh heavily into what you choose. If you are looking to do something low level and high performance, script languages aren't going to cut it.





But, C++ is hard, and "dangerous". Bad C++ code will lock up your PC in an instant. Yay Pointers!!!
Reply:Perl or Python. Scripting is the next wave. Python has more hooks to the GDK widgets that run Linux. Learn Perl and Python won't be hard at all. Plenty of C++ libraries out there. Unbelievable good libraries. It takes script. Script crunches the lines of code down 70%. Since you're so MS, consider .NET and working it with C# if you won't take my advice about script.
Reply:As erorc says, it depends on what you want to do. C++ would be the language of choice for developing large, stand-alone applications. Perl is better for Unix/Linux utilities, and for web scripting. It has great string-processing capabilities, but isn't very GUI-friendly, unless you consider a browser as a GUI. (OTOH, there may be a module for that - Perl has modules for everything.)
Reply:Whichever one best suits a REAL project that people want to use soon, because that will motivate you to get on with it and learn it thoroughly, and at the end you have something tangible to point to.





I'm currently learning Ruby so that I can do a project for a friend to use in his business.
Reply:C++
Reply:In my case, I prefer to learn C first and then C++, although you don't need to learn C first and then C++.





But I rather C first because it's easier to learn. C++ is like an extension of C, so learning C first is like learning C++ at the same time.





But that's my opinion....
Reply:I'll agree with others here, it heavily depends on what you want to do.





Game programming, scientific software, anything that crunches numbers, go for C++.


Web development, unix utilities, or automation software, Perl.


C++ can be a lot to swallow when you're first starting out, but the payoff can be pretty big, aside from the popularity of the language, you'll learn a lot about how computing works, and what lots of other languages do for you behind the scenes (if you've written assembly, you already know what I mean here).





Perl programmers love Perl. To death. I'm not very familiar with the language itself, but all my buddies who use it swear by it. They are also the first to admit to me that it's flexibility is simultaneously it's greatest triumph and downfall; it makes it easy to do things that would be very complex in other languages, but the number of ways to get things done can make understanding old code hard to do.





I'd also toss in a recommendation for Python as a scripting language that's a little more friendly, if not as popular as Perl.

umbrella plant

No comments:

Post a Comment