Bad Programmina analogy
-
Well you never know what could happen in the universe. That's fine assumption. I usually create constants for all the decimal digits 0-9 so that I can change the value if I need it.
If you truly believe you need to pick a mobile phone that "says something" about your personality, don't bother. You don't have a personality. A mental illness, maybe - but not a personality. - Charlie Brooker My Photos/CP Flickr Group - ScrewTurn Wiki
:-D
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong. -- Iain Clarke
[My articles] -
Firstly, VERY OLD. Secondly, Pi may change, it was once defined as 4, and also as 3. Also of interest is the Feynman Point.
------------------------------------ "When Belly Full, Chin Hit Chest" Confucius 502BC
Dalek Dave wrote:
Secondly, Pi may change, it was once defined as 4, and also as 3.
I know well it, sir. We had to use our best chisels to change it in our
FORTRAN
sources.If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong. -- Iain Clarke
[My articles] -
Well you never know what could happen in the universe. That's fine assumption. I usually create constants for all the decimal digits 0-9 so that I can change the value if I need it.
If you truly believe you need to pick a mobile phone that "says something" about your personality, don't bother. You don't have a personality. A mental illness, maybe - but not a personality. - Charlie Brooker My Photos/CP Flickr Group - ScrewTurn Wiki
I always thought that 9 was a bit too much. Can you knock it down to 8.5 for me?
I wanna be a eunuchs developer! Pass me a bread knife!
-
GriffinPeter wrote:
should the value of pi change
But how can they know? No-one has ever found an exact numerical representation of pi. How do you know it has changed, if you never knew previous the value?
xacc.ide
IronScheme - 1.0 beta 3 - out now!
((lambda (x) `((lambda (x) ,x) ',x)) '`((lambda (x) ,x) ',x))leppie wrote:
No-one has ever found an exact numerical representation of pi.
I think it mostly depends on how many pieces you slice it into...
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
-----
"...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001 -
Firstly, VERY OLD. Secondly, Pi may change, it was once defined as 4, and also as 3. Also of interest is the Feynman Point.
------------------------------------ "When Belly Full, Chin Hit Chest" Confucius 502BC
Dalek Dave wrote:
Also of interest is the Feynman Point.
But not as interesting as the Sticky Bead Argument :thumbsup:
Ali
-
Now im not one for second guessing Xerox wanting to change the fundamental laws of the universe.. but.. The primary purpose of the DATA statement is to give names to constants; instead of referring to pi as 3.141592653589793 at every appearance, the variable PI can be given that value with a DATA statement and used instead of the longer form of the constant. This also simplifies modifying the program, should the value of pi change." - FORTRAN manual for Xerox computers ?????
-
GriffinPeter wrote:
should the value of pi change
But how can they know? No-one has ever found an exact numerical representation of pi. How do you know it has changed, if you never knew previous the value?
xacc.ide
IronScheme - 1.0 beta 3 - out now!
((lambda (x) `((lambda (x) ,x) ',x)) '`((lambda (x) ,x) ',x))Nobody has found the exact value of pi doesn't mean that it is a variable. It *is* a constant.
It is a crappy thing, but it's life -^ Carlo Pallini
-
*cough*noneuclideangeometry*cough*
It is a truth universally acknowledged that a zombie in possession of brains must be in want of more brains. -- Pride and Prejudice and Zombies
dan neely wrote:
*cough*noneuclideangeometry*cough*
A cough before and after every word you type?! That sounds nasty. You must see a doctor. :)
It is a crappy thing, but it's life -^ Carlo Pallini
-
Dalek Dave wrote:
Also of interest is the Feynman Point.
But not as interesting as the Sticky Bead Argument :thumbsup:
Ali
Alison Pentland wrote:
the Sticky Bead Argument
Is that KSS? :laugh:
-
GriffinPeter wrote:
should the value of pi change
But how can they know? No-one has ever found an exact numerical representation of pi. How do you know it has changed, if you never knew previous the value?
xacc.ide
IronScheme - 1.0 beta 3 - out now!
((lambda (x) `((lambda (x) ,x) ',x)) '`((lambda (x) ,x) ',x))Exactly. It's only been calculated to a trillion digits, and if you hardcode that and then someone calculates it to a quadrillion then you're going to feel a little silly having to update the value of pi each place you hardcoded it.
cheers, Chris Maunder The Code Project Co-founder Microsoft C++ MVP
-
Now im not one for second guessing Xerox wanting to change the fundamental laws of the universe.. but.. The primary purpose of the DATA statement is to give names to constants; instead of referring to pi as 3.141592653589793 at every appearance, the variable PI can be given that value with a DATA statement and used instead of the longer form of the constant. This also simplifies modifying the program, should the value of pi change." - FORTRAN manual for Xerox computers ?????
sounds like a very dry joke, to me.
-
I always thought that 9 was a bit too much. Can you knock it down to 8.5 for me?
I wanna be a eunuchs developer! Pass me a bread knife!
No, sorry, I only work with integers. It must be either 8 or 9.
If you truly believe you need to pick a mobile phone that "says something" about your personality, don't bother. You don't have a personality. A mental illness, maybe - but not a personality. - Charlie Brooker My Photos/CP Flickr Group - ScrewTurn Wiki
-
Alison Pentland wrote:
the Sticky Bead Argument
Is that KSS? :laugh:
:-O Of course!
Ali
-
Dalek Dave wrote:
Also of interest is the Feynman Point.
But not as interesting as the Sticky Bead Argument :thumbsup:
Ali
Another of Feynman's mind games eh?
------------------------------------ "When Belly Full, Chin Hit Chest" Confucius 502BC
-
Well you never know what could happen in the universe. That's fine assumption. I usually create constants for all the decimal digits 0-9 so that I can change the value if I need it.
If you truly believe you need to pick a mobile phone that "says something" about your personality, don't bother. You don't have a personality. A mental illness, maybe - but not a personality. - Charlie Brooker My Photos/CP Flickr Group - ScrewTurn Wiki
Yeah, but what happens when a new number is discovered between 6 an 7? :)
Chris Meech I am Canadian. [heard in a local bar] In theory there is no difference between theory and practice. In practice there is. [Yogi Berra]
-
Another of Feynman's mind games eh?
------------------------------------ "When Belly Full, Chin Hit Chest" Confucius 502BC
;)
Ali
-
Exactly. It's only been calculated to a trillion digits, and if you hardcode that and then someone calculates it to a quadrillion then you're going to feel a little silly having to update the value of pi each place you hardcoded it.
cheers, Chris Maunder The Code Project Co-founder Microsoft C++ MVP
Chris Maunder wrote:
Exactly. It's only been calculated to a trillion digits, and if you hardcode that and then someone calculates it to a quadrillion then you're going to feel a little silly having to update the value of pi each place you hardcoded it.
Isn't that what Search and Replace is for?
Michael Martin Australia "I controlled my laughter and simple said "No,I am very busy,so I can't write any code for you". The moment they heard this all the smiling face turned into a sad looking face and one of them farted. So I had to leave the place as soon as possible." - Mr.Prakash One Fine Saturday. 24/04/2004
-
Chris Maunder wrote:
Exactly. It's only been calculated to a trillion digits, and if you hardcode that and then someone calculates it to a quadrillion then you're going to feel a little silly having to update the value of pi each place you hardcoded it.
Isn't that what Search and Replace is for?
Michael Martin Australia "I controlled my laughter and simple said "No,I am very busy,so I can't write any code for you". The moment they heard this all the smiling face turned into a sad looking face and one of them farted. So I had to leave the place as soon as possible." - Mr.Prakash One Fine Saturday. 24/04/2004
Michael Martin wrote:
Isn't that what Search and Replace is for?
Ok, let me see, search for a trillion digit value in your source files and replace it with a quadrillion digit value? When that is done your great great grandson will be born. :)
My .NET Business Application Framework My Home Page My Younger Son & His "PET"
-
Michael Martin wrote:
Isn't that what Search and Replace is for?
Ok, let me see, search for a trillion digit value in your source files and replace it with a quadrillion digit value? When that is done your great great grandson will be born. :)
My .NET Business Application Framework My Home Page My Younger Son & His "PET"
The regex would be simple. :)
-
Well you never know what could happen in the universe. That's fine assumption. I usually create constants for all the decimal digits 0-9 so that I can change the value if I need it.
If you truly believe you need to pick a mobile phone that "says something" about your personality, don't bother. You don't have a personality. A mental illness, maybe - but not a personality. - Charlie Brooker My Photos/CP Flickr Group - ScrewTurn Wiki
I worked with some guys who previously had some offshore developers actually do that after they were told to change the hardcoded numbers to constants. (So statements like
x += 2;
got changed tox += TWO;
. It's fortunate they didn't use pi, else it would have become THREE_POINT_ONE_FOUR_ONE_FIVE_NINE.... )Anyone who thinks he has a better idea of what's good for people than people do is a swine. - P.J. O'Rourke