2023 RPN HHC Programming Contest
|
10-16-2023, 03:37 AM
Post: #61
|
|||
|
|||
RE: 2023 RPN HHC Programming Contest
(10-16-2023 02:31 AM)Allen Wrote: indeed.. the others are less practical as they require too many terms for a short program! Meanwhile, by using a(n) = n² + n - 1, for n = 6, 8 instead, I was able to save one more byte: Code:
13 steps, 25 bytes. Or, back to a(n) = n² - n - 1, for n = 7, 9 and assuming a positive number in stack register X, one more step can be saved: Code:
12 steps, 25 bytes. |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 5 Guest(s)