Is there anyway that I could make the function below faster and more optimized with pandas or numpy, the function below adds the sum of seq45 until the elements of it is equivalent or over 10000.The elements that is being added up to seq45 are 3,7,11 in order. The reason why i want to increase the speed is to have have to possibly test 10000 with larger number values like 1000000 and to be processed faster. The answer to this code was gotten from this issue: issue
Code:
Sequence = np.array([3, 7, 11])
seq45= []
for n in itertools.cycle(Sequence):
seq.append(n)
if sum(seq45) >= 10000: break
print(seq45)
Current Perfromance/ Processing time: 71.9ms
