Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function NOD(a,b:int64):int64;
- label 1;
- begin
- result:=0;
- repeat
- a:=a mod b;
- if a=0 then begin Result:=b; goto 1; end;
- b:=b mod a;
- 1:if b=0 then Result:=a;
- until(result>0);
- end;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement