# Struggling understanding my class assignment

I am sure this is very basic for most people on here, but I am just learning. I am having a hard time with understanding functions. Even though I have spent hours watching and reading tutorials. this is our assignment.

// 1. Write (declare) a function named multiplyThemUp
// A. That accepts 3 arguments: all numbers
// B. Multiply all the numbers passed in together.
// C. Returns the product.

// 2. Call the function multiplyThemUp, passing in your top 3 favorite numbers. Save the results of this function to a variable called myProduct. (Another way this instruction could be worded is: declare a variable named myProduct that gets its value by calling multiplyThemUp and passing in your top 3 favorite numbers

I thought this is the right way to start out I thought if someone can see how might be thinking they can see where my error is. Any help would be greatly appreciated thank you. Even a specific recommendation for a video or tutorial. The answer would be great but I really need to understand why.
This is what I have but I know it is wrong.
var multiplyThemUp = (â€ś1,â€ť * â€ś2,â€ť * â€ś3â€ť);
function multiplyThemUp{
return multiplyThemUp;
}

Firstly, welcome to the forums.

While we are primarily here to help people with their Free Code Camp progress, we are open to people on other paths, too. Some of what you are asking is pretty trivial in the Free Code Camp context, so you might find that if youâ€™re not getting the instruction and material you need in your current studies, the FCC curriculum will really help you get started. At a modest guess Iâ€™d say investing a 4-5 hours working through the curriculum here will really pay off. You can find the curriculum at https://freecodecamp.org.

With your current questions, we donâ€™t have enough context to know what you already know or donâ€™t know, or even what language you are working in.

Happy coding

1 Like

Itâ€™s always best to start from the ground upâ€”or in other words, start with the specification(s) in increments, and then worry about the implementation afterwards. This usually means that you start here with this step:

• Save the results of a function to a variable called myProduct:

`var myProduct = multiplyThemUp();`

• â€śPass in your top 3 favorite numbersâ€ť will transform the line into this:

`var myProduct = multiplyThemUp(11, 14, 17);`

• Write (declare) a function named multiplyThemUp:
``````function multiplyThemUp(a, b, c) {
// implementation to go here
}
``````

Hopefully this is enough to get you started.

For the most part, functions in programming behave much like your typical functions in math. This might help explain, if youâ€™re not familiar with mathematical functions: https://www.mathsisfun.com/sets/function.html

1 Like