// taken from the end of chapter 2 in sedgewick's algorithms book // I like the do while loop and the funky variable declaration after the function declaration #include int gcd(u, v) int u, v; { int t; do { if (u 0) && (y > 0)) printf("%d %d %d\n", x, y, gcd(x,y)); }