meanfreepath: (Default)
meanfreepath ([personal profile] meanfreepath) wrote2007-08-23 06:52 pm

(no subject)

Despite all that people say about Python being an easy language to work with, I'm really FORTRAN to be much easier to work with. I'm modifying legacy F77 code, and while it's picky in terms of formatting, to me FORTRAN code is much more straightforward to follow. Clearly I haven't internalized the object-oriented programming paradigm...

[identity profile] blaketh.livejournal.com 2007-08-23 11:13 pm (UTC)(link)
Some things are certainly more straightforward in Fortran, but many things you might want to do aren't. Part of Python's philosophy is that "Simple is better than complex, but complex is better than complicated."

I wrote some Python today and it healed my soul. C++ tears at one's humanity...

[identity profile] greebsnarf.livejournal.com 2007-08-23 11:40 pm (UTC)(link)
Python is better than C++, but C++ is better than everything else.

ah

[identity profile] olifhar.livejournal.com 2007-08-24 06:41 am (UTC)(link)
Don't know if I really agree. My preferences are:

Object Oriented: Ruby (yes I like it much better than Python)

Breakneck Speed: C, and sometimes C++

Pure Badass: Erlang

Bit of a tangent-- I recently heard someone claim that compiled Lisp runs faster than equivalent C code...

paradigm

[identity profile] olifhar.livejournal.com 2007-08-24 06:32 am (UTC)(link)
I remember in High School when Mr. Cave made us stand on our desks to illustrate the concept of 'paradigm shift'. But that was for recursion, not OOP.

'Fraid I'm not with you with the Fortran vs. Python. The jump from BASIC to C++ was an immense relief for me. Then, recently, learning Ruby (in which everything is an Object) was a blissful experience.

I admit I don't actually don't like Python very much, even though everyone says it and Ruby are basically the same.

What did you start programming with back at Swat? Was it IDL? That might explain some things.

More likely, I'd guess you've run into some poor Python programming...

Re: paradigm

[identity profile] meanfreepath.livejournal.com 2007-08-24 01:45 pm (UTC)(link)
Yes, at Swat I primarily programed IDL, although I had taught myself QBASIC before that when I was a kid.

I understand how in Python one creates instances of a class, and how the instance then inherits the attributes of the class. But when reading code, one is thus forced to be constantly flipping back and forth to the definition of the class. Also, what I probably find the most annoying is that bare Python has little numerical capability, and so one almost always needs to import packages like SciPy (http://www.scipy.org/), NumPy (http://numpy.scipy.org/), and Matplotlib (http://matplotlib.sourceforge.net/) to get things done. So getting a given piece of code that depends on all these packages (and others) to run is not trivial, and also the documentation for the different packages ranges from good to sketchy. And because of there being so many different packages available, with different capabilities, Internet searches for help frequently turn up conflicting ideas.

Maybe I just find languages like IDL, Matlab, BASIC, and FORTRAN easier because they are simply more limited.

[identity profile] sildra.livejournal.com 2007-08-24 01:51 pm (UTC)(link)
I find FORTRAN easier because it looks like math in a way that a lot of other languages don't to me. I even like it better than IDL, but I guess I never really learned to use the interfaces and packages that make IDL more powerful than FORTRAN (not inherently more powerful, since at root they're the same language, but easier to tap into). I think I've also forgotten how to do object-oriented programming, having not done it in six years--I think it's harder to just pick up, both in the first place and after a long time of letting yourself forget the concepts. Maybe because it's... more like programming and less like math.