The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 795 - File: showthread.php PHP 7.4.33 (FreeBSD)
File Line Function
/showthread.php 795 errorHandler->error





Post Reply 
(49G) Number of Characters in Roman representation (OEIS A006968)
09-03-2015, 12:32 PM (This post was last modified: 06-15-2017 01:44 PM by Gene.)
Post: #1
(49G) Number of Characters in Roman representation (OEIS A006968)
For integer input N the programme returns the number of letters required for the Roman representation of N, in accord with

http://oeis.org/A006968

Code:

::
  CK1&Dispatch
  BINT1
  ::
    COERCE
    BINT0
    BINT3
    ZERO_DO
    SWAP
    BINT10
    #/
    3UNROLL
    ::
      BINT4
      OVER#>
      ?SEMI
      BINT5
      #=casedrop
      BINT1
      BINT7
      #=casedrop
      BINT3
      BINT8
      #=case
      BINT4
      BINT2
    ;
    #+
    LOOP
    #+
    FPTR2 ^#>Z
  ;
;
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
(49G) Number of Characters in Roman representation (OEIS A006968) - Gerald H - 09-03-2015 12:32 PM



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