Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

4
  • \$\begingroup\$ Heh, I figured Fraction took too much space and a smarter solution could beat a built-in one using the module. +1 \$\endgroup\$ Commented Jun 29, 2021 at 6:05
  • 2
    \$\begingroup\$ As with hyper's solution, everything can be initialized as 1: TIO. After the second iteration a and b are lower by a factor of 2, but that doesn't change the value of the fraction \$\endgroup\$ Commented Jun 29, 2021 at 6:14
  • 1
    \$\begingroup\$ 55 bytes \$\endgroup\$ Commented Jun 29, 2021 at 6:48
  • 1
    \$\begingroup\$ @att Very clever; doing it in reverse (and checking if the result is negative). It took me a while to figure out what was going on! \$\endgroup\$ Commented Jun 29, 2021 at 7:11