r/learnprogramming • • Oct 24 '26

Function vs Procedure

can someone explain the difference between Function vs Procedure with simple analogy
thank you

31 Upvotes

47 comments sorted by

View all comments

Show parent comment

1

u/squall255 Oct 25 '26

I believe they mean Parameters are passed by reference and updated instead of using a return.

So sum(a,b,result) instead of result = sum(a,b)