Post Reply 
challenge for programmable calculators
12-22-2013, 07:03 PM
Post: #24
RE: challenge for programmable calculators
Just for the record, here is my wp34s program:
Code:
001:      LBL A
002:      9
003:      STO 01
004:      9
005:      STO 02
006:      RCL 01
007:      RCL[times] 02
008:      RCL 01
009:      x[^2]
010:      RCL[times] 02
011:      RCL 02
012:      x[^2]
013:      RCL[times] 01
014:      +
015:      DEC X
016:      RCL 01
017:      SDL 001
018:      RCL+ 02
019:      SDL 001
020:      +/-
021:      SLVQ
022:      x[<->] Y
023:      FP?
024:      SKIP 011
025:      9
025:      x<? Y
027:      SKIP 008
028:      x[<->] Y
029:      RCL 02
030:      SDL 001
031:      +
032:      RCL 01
033:      SDL 002
034:      +
035:      STOP
036:      DSE 02
037:      BACK 031
038:      DSE 01
039:      BACK 035
040:      END

A --> 144 ; first solution ( ~ 3 sec )
R/S --> 135 ; second solution
R/S --> 9 ; no more solutions

It seems the complexity of the inner loop outweighs the gain obtained by the elimination of the third loop.
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: challenge for programmable calculators - Gerson W. Barbosa - 12-22-2013 07:03 PM
Proof using number theory - cruff - 12-24-2013, 05:43 PM
RE: challenge for programmable calculators - radwilliams - 12-24-2013, 05:57 PM



User(s) browsing this thread: 1 Guest(s)