Pi Approximation Day
|
07-23-2022, 06:46 PM
Post: #13
|
|||
|
|||
RE: Pi Approximation Day
(07-23-2022 11:59 AM)Gerson W. Barbosa Wrote: Not as fun, but we can still rewrite Valentin’s intentionally slightly obfuscated program Without recall-arithmetic it uses even fewer bytes: Code: 00 { 27-Byte Prgm } Using a register we can translate it for other HP calculators as well. HP-15C: Code: 001 { 44 0 } STO 0 HP-25: Code: 01: 23 00 : STO 0 We can even do it on the HP-35 if we consider the following manual steps a program. Initialize: Code: CLR Repeat until 0: Code: ENTER↑ ENTER↑ × + Finalize: Code: R↓ While we could start subtracting the terms from an initial value of 10, it is better to start the summation from 0 to avoid cancellation. |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)