This program was made for the Project Euler problem "Multiples of 3 and 5". Although this does solve the problem, I want to further improve on the code. Specifically, make it so that you may input an unlimited number of items, instead of being limited to two base numbers.
Somehow, I figured to use a list, make the function recursive, or use a function within the function.
def SumOfMultipleBase2(multiple1 , multiple2 , start , limit):
sum = 0
for i in range(start , limit):
if 1%multiple1 == 0 or 1%multiple2==0:
sum += 1
print('The sum of the multiples of ' , multiple1, ' or' , multiple2 , 'between ', start , ' to ' , limit , ' is ' , sum , '.')