quotient(6,4); remainder(6,4); gcd(4,6); load(functs); lcm(4,6); div(n):=(s:[], for k from 1 thru n do if remainder(n,k)=0 then s:append(s,[k]),s); div(6); comdiv(n,p):=(s:[], for k from 1 thru n do if (remainder(n,k)=0 and remainder(p,k)=0) then s:append(s,[k]),s); pgcd(n,p):=last(comdiv(n,p)); pgcd(4,6); commult(n,p):=(s:[], for k from 1 thru n*p do if (remainder(k,n)=0 and remainder(k,p)=0) then s:append(s,[k]),s); ppcm(n,p):=first(commult(n,p)); ppcm(4,6); for k from 1 step 0 while k^3+19*k^2+3<1000 do (k:k+1,s:k); s; prime(n):=(s:0,for k from 2 step 1 while s