/maxPairwiseProductAlgorithm

My implementation of a maximum pairwise product algorithm in C++11

Primary LanguageC++

maxPairwiseProductAlgorithm

  • To compile, run g++ -std=c++11 -O3 main.cpp -o pairwise
  • To run: ./pairwise
  • Enter in the size of the list/array
  • Enter in the numbers to fill the array
  • For example this might look like:

4

12 10000 5000 30

  • Output would be:

1 : 10000/2 : 5000 (Index position in array : number)

50000000 (Product of 10000 and 5000)

To stress test, comment out parts of the code as explained in main.cpp and recomplie