Search Apps Documentation Source Content File Folder Download Copy Actions Download State String Boolean Number Struct Map Slice Pointer Function Closure Reference Nil Package Type Interface Unknown

/romannum package

Overview

Package romannum is an on-chain port of the classic Roman-numeral converter kata: ToRoman/FromRoman. Pure and deterministic — no time, randomness or I/O.

Function

ToRoman

func ToRoman(n int) string

ToRoman renders an integer in 1..3999 as a Roman numeral. It panics if n is out of range.

Param

Command

gnokey query vm/qeval -remote "https://rpc.topaz.testnets.gno.land" -data "gno.land/r/g12cs4cehujpffpjpywmkqj43m6u5ya53nj69sjz/romannum.ToRoman()"

Result