Cumulative product of a list
问题 I have implemented a list of all prime numbers from a set amount. What I'm trying to do is hard to explain so I'll just show it with some hard code: euclst = [] euclst.append((primelst[0]) + 1) euclst.append((primelst[0] * primelst[1]) + 1) euclst.append((primelst[0] * primelst[1] * primelst[2]) + 1) .... So essentially I'm trying to take a single element in order from my prev list and multiplying it exponentially I guess and appending it to my other list. I realized that I could just do this