int delphi(int a,int b){int i;if a>b then{i=max(a,b);a=b;b=i;}do{i=b mod aif i!=0 then{b=aa=i}}while (i!=0)return a}
function gcd(a,b:integer):integer; begin if b=0 then gcd:=a else gcd:=gcd (b,a mod b); end ;