From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 109fba,b87849933931bc93 X-Google-Attributes: gid109fba,public X-Google-Thread: fac41,b87849933931bc93 X-Google-Attributes: gidfac41,public X-Google-Thread: 103376,b87849933931bc93 X-Google-Attributes: gid103376,public X-Google-Thread: 1108a1,b87849933931bc93 X-Google-Attributes: gid1108a1,public X-Google-Thread: 114809,b87849933931bc93 X-Google-Attributes: gid114809,public From: bower@intuitive.co.uk (Andy Bower) Subject: Re: OO, C++, and something much better! Date: 1997/01/24 Message-ID: <32e87d25.0@194.131.7.3>#1/1 X-Deja-AN: 212209029 references: <5bphq4$5js@mulga.cs.mu.OZ.AU> <32E05FAF.47BA@concentric.net> <5buodl$bci@boursy.news.erols.com> <32E2FEC7.2F7B@concentric.net> <6PE5zLpF3RB@herold.franken.de> <32E57E2B.6CB7@epix.net> <32E57FBC.2325@epix.net> <5c4ita$3qs@mulga.cs.mu.OZ.AU> <32E6797A.6E21@parcplace.com> organization: Intuitive Systems Ltd. newsgroups: comp.lang.eiffel,comp.lang.ada,comp.lang.c++,comp.lang.smalltalk,comp.object Date: 1997-01-24T00:00:00+00:00 List-Id: Eric Clayberg wrote: >Fergus Henderson wrote: >> I don't know how it got its start there, but I have heard that it got a >> bit of a boost after the stockmarket crash in '87. Apparently the >> volume of shares traded was very high, and many financial programs >> failed, because the numbers involved were so large that they overflowed >> various limits, but the Smalltalk programs kept running, because >> Smalltalk quietly switches to using floating point arithmetic when >> integer arithmetic overflows. (Well, that's the rumour anyway. I >> don't know how much truth there is to it.) >Actually, Smalltalk transparently switches to using "large" integers >that have no limits on size. In fact, it's actually fun to run large >factorials in Smalltalk to see how large an integer it will generate. >VisualSmalltalk will calculate the result of "1000 factorial" in a >second or two and display the results. BTW, the result of that >expression is: :-) >large number snipped< Eric, Perhaps an even more amusing trial, to embarass those used to languages that rely soley on fixed size integer and floating point arithmetic, is to use Smalltalk to calculate the largest known prime number. To do so, evaluate: (2 raisedToInteger: 1257787)-1 A word of caution, however. DON'T DISPLAY the result. In Dolphin Smalltalk it takes a mere couple of seconds to calculate the prime but to print out it's 378,632 digits demanded a whole evening of toil for our Pentium 200. For this reason, I am not embedding the result to this posting. Happy number crunching Andy Bower bower@intuitive.co.uk