Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

Re: I dislike object-oriented programming in general

by Anonymous Monk
on Oct 22, 2007 at 12:13 UTC ( [id://646430]=note: print w/replies, xml ) Need Help??


in reply to I dislike object-oriented programming in general

"However, this is a sad price to pay, because anthropomorphic terminology leads to operational thinking. By operational thinking, I mean trying to understand a program in terms of how it is executed on a computer. Usually this involves keeping mentally track of variables and their values, following one statement after another checking what it does to data, and doing case analysis with if-then-else blocks. You are knee-deep in problems once you start trying to understand loops operationally (does it terminate? will the loop counter be always inside the bounds?)."

It is sometimes argued that the inability of people to keep track of variables is one reason that methods should be kept short. Some have argued that the number of local variables should be reduced, others that they should be eliminated altogether. However, people have difficulty thinking mathematically, which is possibly why it took so long (in terms of the history of computing) for purely functional languages to arise. Both Object Oriented, and Functinal, programming may be regarded as approaches to making code understandable: OO by intuitive understanding about manipulating objects, funtional by mathematical proof.

So when you suggest we abandon operational thinking, what do we put in its place? Traditionally, operational thinking is what it has meant to understand how a program works.

This goes to the heart of what good software design is about, because if we are to design code to be read, more than to be executed, then we must design it to be understood. So if that understanding is reached other than by operational thinking, it will colour how we write.

I don't have an account here, and I seem to be showing up in preview as vroom, whoever that is.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://646430]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others wandering the Monastery: (5)
As of 2024-03-29 10:16 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found