vault backup: 2023-11-24 15:51:06
This commit is contained in:
parent
55a95b0cac
commit
68295d1f23
@ -157,7 +157,7 @@ def mu_sum(n: int) -> int:
|
||||
```
|
||||
|
||||
## Exercise 2.1
|
||||
```
|
||||
```python
|
||||
def euclid(a, b):
|
||||
if (a <= b):
|
||||
raise ValueError("a must be superior to b")
|
||||
@ -169,4 +169,10 @@ def euclid(a, b):
|
||||
a = b
|
||||
b = r
|
||||
return oldr
|
||||
|
||||
# OR
|
||||
def euclid(a, b):
|
||||
while b != 0:
|
||||
(a, b) = (b, a%b)
|
||||
return a
|
||||
```
|
Loading…
x
Reference in New Issue
Block a user