I'm in the process of trying to teach myself lambda expressions in C# and I've seem to have stumped myself...
This is essentially what I am trying to accomplish, please assume that ar1 & ar2 will always have the same length.
double sum = 0;
for(int x=0; x<size; x++){
sum += (ar1[x]*ar2[x]);
}
Notice the Arrays are being multiplied.
Is there an Lambda function that can accomplish this in a single line?
Thank you