Advertisement
Guest User

Untitled

a guest
Jan 24th, 2017
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.18 KB | None | 0 0
  1. Given X and Y integers < 2^30-1
  2. while true
  3. If X == Y
  4. Terminate fail
  5. If Y > X
  6. swap X,Y
  7. If (X,Y) found in Q
  8. Terminate success
  9. Add (X,Y) to Q
  10. X -= Y
  11. Y += Y
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement