Greatest common divisor: Difference between revisions

dc implementation
m (Moving 8086 Assembly to x86 Assembly)
(dc implementation)
Line 408:
return gcd(a, b-a);
}</lang>
 
=={{header|Dc}}==
 
<lang dc>[Lbsasb]ss [lsxlFx]st [lalb%d0>t]sF sasblFxf</lang>
This code assumes that there are two integers on the stack. So It may be tested it with something like that:
<pre>echo '20 25 [Lbsasb]ss [lsxlFx]st [lalb%d0>t]sF sasblFxf' | dc</pre>
 
=={{header|E}}==
Anonymous user