/* GCD Greatest Common Divisor Scriptol example, public domain source at www.scriptol.org */ void pgcd(int divisor, int remainder) int x, y if remainder = 0 print "PGCD:", divisor return /if x = int(abs(divisor/remainder)) y = divisor - (remainder * x) print "$divisor/$remainder =", x, " remainder ", y pgcd(remainder, y) return int numa, numb print "Enter two numbers:" input "First number:", numa input "Second number:", numb pgcd(numa, numb)