inner_product

Computes and returns the value of a product of the values in a range.

template <class InputIterator1, class InputIterator2, class T>
T inner_product(InputIterator1 first1, InputIterator1 last1, InputIterator2 first2, T init);
template <class InputIterator1, class InputIterator2, class T, class BinaryOperation1, class BinaryOperation2>
T inner_product(InputIterator1 first1, InputIterator1 last1, InputIterator2 first2, T init,BinaryOperation1 binary_op1, BinaryOperation2 binary_op2);
  
Remarks

The value of the product starting with an initial value in a range is returned. In the function with the operation argument it is the product after the operation is performed.