Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re^2: Computers declared extraneous

by Aristotle (Chancellor)
on Oct 18, 2002 at 12:31 UTC ( #206287=note: print w/replies, xml ) Need Help??


in reply to Re: Computers declared extraneous
in thread Cheap idioms

You could execute it and find out.

Assume that the program produces no messages whatsoever. You run it without parameters, it says nothing. You pass a file as parameter, it says nothing. You list the directory, there's no new file, the one passed hasn't changed. Hmm, that probably wasn't it.

Or suppose you have a library with absolutely no documentation.

Tell me how you would go about finding out what the code does at this point.

Of course the fact that code is executable by a computer is not quite incidental, but the essence of that saying is that you should write your code as if it were. In fact, you are already thinking by these lines, even if you don't realize it.

Makeshifts last the longest.

Replies are listed 'Best First'.
Re^2: Computers declared extraneous
by rir (Vicar) on Oct 18, 2002 at 17:50 UTC
    (For the tired audience, Ovid & I are discussing/quibbling/seeking consensus on a big nit. If you take it seriously it can impact how you work and live. )

    programs are letters from one programmer to another. The fact that computers can execute them is only incidental.

    To say that the "essential meaning" of the above phrase is that you should write your code as if its executability is incidental is Humpty-Dumptyism.

    Implied by the view you expressed is that these letters that really are letters deserve, or normally receive, more care and accuracy than programs.

    I realize that clear code is important, you could have cited that from any of my posts in this thread. But I am not thinking like you. I do not support the statement

    the fact that code is executable ... is not quite incidental

    What my code does when executed is the primary issue. The only code that I've written that has not been executed, was written as an adjunct to creating other code that was.

      The only code that I've written that has not been executed, was written as an adjunct to creating other code that was.

      Please explain how code that creates other code was never executed, but the code that was never created by the aforementioned never-executed code, was, in fact, executed.

        I said it was an adjunct to creating code not that it created code.

        Specifically I occasionally write code just to clarify things in my mind, with the expectation that this clarity will aid with other code. Usually I use pen and paper for this, that is just comfortable somehow.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://206287]
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (9)
As of 2017-10-19 21:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My fridge is mostly full of:

















    Results (257 votes). Check out past polls.

    Notices?