Solve e700 because I have looked at it a while ago and it is easy.
parent
743966c7b8
commit
eb7ec037d2
|
@ -0,0 +1,16 @@
|
||||||
|
def euler_700():
|
||||||
|
mod = 4503599627370517
|
||||||
|
mul = 1504170715041707
|
||||||
|
result = mul
|
||||||
|
while mul > 1:
|
||||||
|
while mod > mul:
|
||||||
|
mod = mod % mul
|
||||||
|
mul -= mod
|
||||||
|
result += mul
|
||||||
|
return result
|
||||||
|
|
||||||
|
|
||||||
|
if __name__ == "__main__":
|
||||||
|
solution = euler_700()
|
||||||
|
print("e700.py: " + str(solution))
|
||||||
|
assert solution == 1517926517777556
|
Loading…
Reference in New Issue