More GCD Applet Code
public boolean action(Event e, Object o) {
if (" GCD: ".equals(o)) {
x = Integer.parseInt(a.getText());
y = Integer.parseInt(b.getText());
z = gcd(x,y);
c.setText(Integer.toString(z));
}
return true;
}
}
Previous slide
Next slide
Back to first slide
View graphic version