Function

What is the difference between a function() and a method()

I found myself asking this question because the two seem painfully similar. I found the following answer at Stackoverflow, Andrew Edgecombe explains

A function is a piece of code that is called by name. It can be passed data to operate on (i.e. the parameters) and can optionally return data (the return value).

All data that is passed to a function is explicitly passed.

Subscribe to RSS - Function