forked from tdwojak/Python2017
Update 'labs02/task08.py'
This commit is contained in:
parent
d17a0deeed
commit
dda70b0c8d
@ -7,8 +7,16 @@ przez 3 lub 5 mniejszych niż n.
|
||||
"""
|
||||
|
||||
def sum_div35(n):
|
||||
s=0
|
||||
i=0
|
||||
while i<n:
|
||||
if (i%3==0) or (i%5==0):
|
||||
s=s+i
|
||||
i=i+1
|
||||
return s
|
||||
pass
|
||||
|
||||
|
||||
def tests(f):
|
||||
inputs = [[10], [100], [3845]]
|
||||
outputs = [23, 2318, 3446403]
|
||||
|
Loading…
Reference in New Issue
Block a user