Sha256: 7f136d2fba63bccef83b270b580f18be0f8e6809bc7a9ff4d94f4e659d05e205

Contents?: true

Size: 495 Bytes

Versions: 10

Compression:

Stored size: 495 Bytes

Contents

USING: combinators io kernel math math.functions math.order
math.parser prettyprint ;

"a=" "b=" [ write readln string>number ] bi@
{
    [ + "sum: " write . ]
    [ - "difference: " write . ] 
    [ * "product: " write . ]
    [ / "quotient: " write . ]
    [ /i "integer quotient: " write . ]
    [ rem "remainder: " write . ]
    [ mod "modulo: " write . ]
    [ max "maximum: " write . ]
    [ min "minimum: " write . ]
    [ gcd "gcd: " write . drop ]
    [ lcm "lcm: " write . ]
} 2cleave

Version data entries

10 entries across 7 versions & 1 rubygems

Version Path
zettacode-0.1.7 files.zettacode/arithmetic.integer/factor.txt
zettacode-0.1.6 files.zettacode/arithmetic.integer/factor.txt
zettacode-0.1.6 files.zettacode2/arithmetic.integer/factor.txt
zettacode-0.1.5 files.zettacode/arithmetic.integer/factor.txt
zettacode-0.1.5 files.zettacode2/arithmetic.integer/factor.txt
zettacode-0.1.4 files.zettacode/arithmetic.integer/factor.txt
zettacode-0.1.4 files.zettacode2/arithmetic.integer/factor.txt
zettacode-0.1.3 files.zettacode/arithmetic.integer/factor.txt
zettacode-0.1.2 files.zettacode/arithmetic.integer/factor.txt
zettacode-0.1.1 zettacode.files/arithmetic.integer/factor.txt