Parallel/Functional Programming vs OOP/C++?

A place to discuss the implementation and style of computer programs.

Moderators: phlip, Moderators General, Prelates

Ankit1010
Posts: 135
Joined: Fri Feb 11, 2011 11:32 am UTC

Parallel/Functional Programming vs OOP/C++?

Postby Ankit1010 » Fri May 27, 2011 6:37 am UTC

I'm studying CS at the undergrad my level, and my university recently changed the new CS curriculum, meaning I now have a choice between the old one and the new one.
The old one stresses stuff like OOP in Java, a little bit of shell & perl scripting and some coding in C++, whereas the new one replaces this with things about parallel programming/data structures, functional programming, and verification of correctness of code.
I'm leaning towards the new one since I think parallel programming is the way of the future. On the other hand, I also love scripting, and getting my hands dirty with C.What do you guys think?

User avatar
zed0
Posts: 179
Joined: Sun Dec 17, 2006 11:00 pm UTC

Re: Parallel/Functional Programming vs OOP/C++?

Postby zed0 » Fri May 27, 2011 10:28 am UTC

While I'm not a CS student (I'm an engineer who does a fair bit of programming), I would go for the new, more formal, CS course.
I think that scripting and programming are things that you will pick up naturally while doing other things such as implementing algorithms you're learning the theory behind.
I've picked up scripting and programming by day to day usage of a linux box and doing Project Euler whereas I still have no idea about a lot of algorithms which I would quite like to know about.

EvanED
Posts: 4331
Joined: Mon Aug 07, 2006 6:28 am UTC
Location: Madison, WI
Contact:

Re: Parallel/Functional Programming vs OOP/C++?

Postby EvanED » Fri May 27, 2011 2:15 pm UTC

I'm with zed0. You'll get to mess around with C later. And it sounds like you already have some background in the sort of stuff that is likely to be covered by the old one.

Moose Hole
Posts: 398
Joined: Fri Jul 09, 2010 1:34 pm UTC

Re: Parallel/Functional Programming vs OOP/C++?

Postby Moose Hole » Fri May 27, 2011 8:25 pm UTC

Yeah, don't go to school to learn language, go there to learn concepts. Syntax is easy.

User avatar
headprogrammingczar
Posts: 3072
Joined: Mon Oct 22, 2007 5:28 pm UTC
Location: Beaming you up

Re: Parallel/Functional Programming vs OOP/C++?

Postby headprogrammingczar » Sat May 28, 2011 12:37 am UTC

Agreed. The language/scripting degree already exists, and is called "software engineering".
<quintopia> You're not crazy. you're the goddamn headprogrammingspock!
<Weeks> You're the goddamn headprogrammingspock!
<Cheese> I love you

User avatar
thoughtfully
Posts: 2253
Joined: Thu Nov 01, 2007 12:25 am UTC
Location: Minneapolis, MN
Contact:

Re: Parallel/Functional Programming vs OOP/C++?

Postby thoughtfully » Sat May 28, 2011 3:22 am UTC

I'd go for the new stuff as well, but I should note that parallel programming really only works for problems that are parallizable. Most stuff does not become any faster when you have four cores instead of one. But study it, it's definitely worthwhile stuff. I'm dubious of the "wave of the future" hype, though.
Image
Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away.
-- Antoine de Saint-Exupery

User avatar
Berengal
Superabacus Mystic of the First Rank
Posts: 2707
Joined: Thu May 24, 2007 5:51 am UTC
Location: Bergen, Norway
Contact:

Re: Parallel/Functional Programming vs OOP/C++?

Postby Berengal » Sat May 28, 2011 3:52 pm UTC

thoughtfully wrote:I should note that parallel programming really only works for problems that are parallizable.
Concurrency is a harder issue. When you want to parallelize you're going to have the most trouble creating an algorithm that is parallelizeable. Implementing it is comparatively easy, and several languages have support for dealing with the low-level details of dispatching work (e.g. futures, data-parallellism, fork-join). Concurrency, on the other hand, isn't concerned with speed, but with latency, and the big bad wolf isn't data dependencies but synchronization.

Most "wave of the future" hype (as well as the actual research that precedes it) for multi-threaded programming deals with concurrency, not parallelism. The uptake of message passing and the actor model, the emergence of STM, Clojure's whole "identity" philosophy; all these are responses to the hardships of writing concurrent code with mutexes and semaphores, not writing parallel code. (There's still lots of interesting research going on in parallelism with several new and interesting languages being targeted at the high-performance parallelism niche emerging, steadily improving libraries and support for GPGPU etc. but these are mostly constrained to academia and science while developers in other domains just cheer them on, or participate on a hobby basis).
It is practically impossible to teach good programming to students who are motivated by money: As potential programmers they are mentally mutilated beyond hope of regeneration.

EvanED
Posts: 4331
Joined: Mon Aug 07, 2006 6:28 am UTC
Location: Madison, WI
Contact:

Re: Parallel/Functional Programming vs OOP/C++?

Postby EvanED » Sat May 28, 2011 6:22 pm UTC

thoughtfully wrote:I'd go for the new stuff as well, but I should note that parallel programming really only works for problems that are parallizable. Most stuff does not become any faster when you have four cores instead of one.

There are problems which are fundamentally less parallelizable than others, but I am not even remotely convinced that's the reason "most stuff does not become any faster" on more cores. I suspect that almost any (compute-bound) task where a significant effort has not already been spent would be made noticeably faster with better parallelism.


Return to “Coding”

Who is online

Users browsing this forum: No registered users and 10 guests