Default Value

Rick Johnson rantingrickjohnson at gmail.com
Sat Jun 22 11:07:20 EDT 2013


> See my blog [...]
> for a history of wishes akin to yours and lessons not
> learnt. In short the problems accruing from unconstrained
> imperative programming are severe and the solutions are
> hard. In the meanwhile, goals such as your 'keep-
> procedures-stateless' can and should certainly be
> practised in the human sphere even if not implemented in
> the programming language sphere.  The aggregation of such
> 'best-practices' is what I call FP as an ideology rather
> than as technology. 
>
> I have a collection here [...]
> And I would welcome suggestions/discussions on the same.

Here are some statements from your blog, i have made a few
tweaks to the text (mainly structure) so as to render it
more readable. 

> Unfortunately these are the exceptions.  In the vast
> majority of cases, the quest for generalities only
> produces rubbish. So lets see how the... The Philosophy of
> OO fares in this regard.
> 
> OO starts off its philosophical sojourn with the dogma:
> Everything is an object I will start with a variation that
> is slightly less nonsensical but easier to debunk;
> Everything can be modeled as a class
> 
> Now if we start looking at the justifications of this
> statement we would find certain methodological directives
> such as Identify the nouns in the use-case and make them
> classes In itself this is - as a methodology - not
> objectionable.
> 
> So for example if we are presented with the standard
> example of a customer coming to an ATM and making a
> transaction, this methodology tells us that it may be a
> good idea to make customer and ATM into classes - so far
> so good.
> 
> And what about transaction? Yes we could make it into a
> class also, but as we shall see, blanket- adding the set
> of abstract nouns into the set of common nouns as class-
> ifiable objects gets us into trouble.

No, the transaction itself need NOT be a custom object.

> So for example, if the use-case contained a statement
> like: In order to safeguard customer-satisfaction, the
> ATM's performance shall not degrade beyond 3 seconds
> response time.
> So now - according to our methodology - we need to
> make performance, response-time and even customer-
> satisfaction(!!) into classes.

LOL! 

Only a fool, or a religious OOP extremist, would create
custom objects for such things. Although, if he were forced
to use Java, he wouldn't have any choice would he? Poor
basterd! >:D

But my point is, OOP is not a cure-all for every problem, in
fact, it can overly complicate many problems. For instance,
being forced to write an object definition for a simple hello
world program in Java is nothing less than pure sadism --
but that's why i don't use Java unless i'm forced!

OTOH, from skimming a few other threads in your blog, you
seem to long for some salvation of FP to save all our souls
from the eternal damnation of IP, like a Christian
longing for the second coming of Christ!

 "Take us away to streets paved in gold!"

I sorry, but FP is not going to wash our sins clean. In
fact, if taken too seriously, FP leads to preaching
professors, intellectually unstimulated students, and
semesters of wasted time that could have been better spent
honing practical *real world* skill sets. 

    ########################################################
    #                    Tip of the Day                    #
    ########################################################
    # Remember, whilst the professor's tenure will         #
    # guarantee he gets a paycheck even for producing      #
    # rubbish, you won't be afforded such luxuries in the  #
    # real world.                                          #
    ########################################################

 "If it IS to be, then it's up to ME"

The point is, no one paradigm is going to save us from the
devil. We must take from each style it's positive
attributes, and reject it's negative attributes. The art of
intelligently applying multiple paradigms to solve complex
problems should be held up as the pinnacle of greatness. If
your going to worship something, worship achievement.




More information about the Python-list mailing list