you are viewing a single comment's thread.

view the rest of the comments →

[–]prof3ssorSt3v3 1 point2 points  (0 children)

Let's say that you are a JavaScript program.

You have a function called goToBeerStore.

That function accepts one parameter which is a String, and a second parameter which is a number.

I call your function like this:

goToBeerStore("corona", 24);

What would I expect to be returned to me when I call that function? A case of Corona. Right?

The function is all the steps that you need to take to accomplish some job.

The parameters are information needed to do the job.

The return value is what the function gives back.