sumproduct

double sumproduct(double* first1, double* last1, double* first2);

Returns the sums of products of the elements in [first, last).

Parameters:
first1Beginning iterator for the first container of elements.
last1Ending iterator for the first container of elements.
first2Beginning iterator for the second container of elements.

Returns:
Sum of the products

Usage:
double s[4] = {1.1, 2.2, 3.3, 4.4};
int t[4] = {4, 3, 2, 1};
double sm = sumproduct(s, s + 4, t);

Header:
#include "descript.h"