Question

Maybe someone can help me with the following problem in basic Excel because Google is unable to. I have a column of numbers, for example A1:A10 and I need the following operation:

I need the multiplication of all numbers (like =Product(A1:A10)) but I also need that each element before multiplication gets added by a constant 'c', for example 5.

So the column needs to be added with c and then all entries multiplicated.

I know you can just add the constant in the original column, but I need to do this for multiple values, so I don't want to copy my data constantly. Is there a formula which can do this? Something like =Product(A1:A10...+5).

Was it helpful?

Solution

You can use the formula you suggested

=PRODUCT(A1:A10+5)

....but that's an "array formula" so you have to enter with CTRL+SHIFT+ENTER key combination

Put formula in cell then select that cell and press F2 to select formula. Now hold down CTRL and SHIFT while presssing ENTER. If done correctly you will see curly braces around the formula so it looks like this:

{=PRODUCT(A1:A10+5)}

to avoid "array entry" you can add an INDEX function, i.e. this regular version

=PRODUCT(INDEX(A1:A10+5,0))

OTHER TIPS

You can put the constant in a cell and refer to that cell in all your copied formulas using $ notation.

Another option is to actually put the constant as a column in the list of numbers and use the value of each row to multiply. BUT when putting in the constant, type in first line only and make all the others be the value of the line above. That way when you change the constant just in the first aline it changes all the way down the column.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top