Write a short C++ program that takes two arguments of type STL vector < double>, a and b, and returns the element-by-element product of a and b. That is, it returns a vector c of the same length such that c[i] = a[i] ·b[i].

Chapter 1, Creativity #8

This problem has been solved!


Do you need an answer to a question different from the above? Ask your question!

Write a short C++ program that takes two arguments of type STL vector< double>, a and b, and returns the element-by-element product of a and b. That is, it returns a vector c of the same length such that c[i] = a[i] ·b[i].

Related Book For answer-question

Data Structures And Algorithms In C++

2nd Edition

Authors: Michael T. Goodrich, Roberto Tamassia, David M. Mount

ISBN: 9780470383278