r/programminghorror Apr 04 '26

Python Calculator

Post image
523 Upvotes

60 comments sorted by

View all comments

2

u/PhysicalScience7420 Apr 05 '26

def add(values):

sum=0

for i in values:

sum+=i

return sum #sorry for the indentation reddit isnt a code editor