HP 50g Programming Competition: How Many Partitions of an Integer in 4 Squares
|
04-15-2018, 03:34 PM
(This post was last modified: 04-15-2018 03:35 PM by Thomas Ritschel.)
Post: #12
|
|||
|
|||
RE: HP 50g Programming Competition: How Many Partitions of an Integer in 4 Squares
(04-15-2018 03:09 PM)Gerald H Wrote: Programme returns wrong values for input 0 & 1. For input 1 it returns 8, which should be correct (= 2*4 possibilities). But you're right, for 0 it should return 1 (not 8). The following version of the program also treats 0 correctly: Code: %%HP: T(3)A(R)F(.); |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)