Greatest common divisor: Difference between revisions

indentation
(smalltalk code cleanup: the copy is not needed; Integers are immutable.)
(indentation)
Line 2,487:
<lang smalltalk>|gcd_iter|
 
gcd_iter := [ :a :b | |u v| u := a. v := b.
|u v|
u := a. v := b.
[ v > 0 ]
whileTrue: [ |t|
Line 2,494 ⟶ 2,496:
v := t rem: v
].
u abs
].
 
Anonymous user