Post Reply 
OEIS A228297: Need Help to Find Algorithm
09-16-2017, 04:41 PM
Post: #3
RE: OEIS A228297: Need Help to Find Algorithm
Thank you, Thomas for your suggestion, resulting in the programme below, which does function, but for large input, eg 20, it becomes extremely slow (31.5s).

Suggestions welcome.

Code:
Size: 180.

CkSum: # 2911h

::
  CK1&Dispatch
  BINT1
  ::
    %ABSCOERCE
    '
    ::
      DUP
      BINT6
      #<
      ITE
      ::
        BINT0
        #MAX
      ;
      ::
        DUP
        BINT6
        #=
        casedrop
        BINT5
        DUP
        DUP#1-
        1GETLAM
        EVAL
        #-
        1GETLAM
        EVAL
        OVER
        #1-
        DUP#1-
        1GETLAM
        EVAL
        #-
        1GETLAM
        EVAL
        #+
        OVER
        #2-
        DUP#1-
        1GETLAM
        EVAL
        #-
        1GETLAM
        EVAL
        #+
        OVER
        #3-
        DUP#1-
        1GETLAM
        EVAL
        #-
        1GETLAM
        EVAL
        #+
        SWAP
        #4-
        DUP#1-
        1GETLAM
        EVAL
        #-
        1GETLAM
        EVAL
        #+
      ;
    ;
    DUP1LAMBIND
    EVAL
    ABND
    UNCOERCE
  ;
;
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: OEIS A228297: Need Help to Find Algorithm - Gerald H - 09-16-2017 04:41 PM



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