Post Reply 
50g Mini-Challenge: Number of positive divisors of x!
10-04-2017, 03:40 PM
Post: #26
RE: 50g Mini-Challenge: Number of positive divisors of x!
A more efficient version of the programme:

Size: 124.

CkSum: # 6E3Ch

Code:
::
  CK1&Dispatch
  # FF
  ::
    ZINT 1
    SWAP
    ZINT 0
    BEGIN
    FPTR2 ^Prime+
    2DUP
    Z>=
    WHILE
    ::
      2DUP
      ZINT 0
      SWAPROT
      BEGIN
      OVER
      FPTR2 ^ZQUOText
      ROTOVER
      FPTR2 ^RADDext
      3UNROLL
      FPTR2 ^DupQIsZero?
      UNTIL
      2DROP
      ZINT 1
      FPTR2 ^RADDext
      4ROLL
      FPTR2 ^RMULText
      3UNROLL
    ;
    REPEAT
    2DROP
  ;
;
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: 50g Mini-Challenge: Number of positive divisors of x! - Gerald H - 10-04-2017 03:40 PM



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