From 159feb0dac129cab17414f4f98068afe7a0e4f00 Mon Sep 17 00:00:00 2001 From: Bob Polis Date: Sat, 12 Sep 2020 18:31:58 +0200 Subject: [PATCH] added lcm function --- code/gcd.txt | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/code/gcd.txt b/code/gcd.txt index bcdeb55..7e0fbdb 100644 --- a/code/gcd.txt +++ b/code/gcd.txt @@ -31,9 +31,23 @@ gto :gcd-ret $u ret -:main -4 -16 +:lcm +=b +=a +$a +$b >gcd fun +=gcd +$a +$gcd +div +$b +mul +ret +:main +21 +6 +>lcm +fun end