Updated response
This commit is contained in:
parent
0a954e09da
commit
af5a611951
5 changed files with 44 additions and 3 deletions
|
|
@ -3,7 +3,7 @@
|
|||
#include <vector>
|
||||
#include <cmath>
|
||||
#include <algorithm>
|
||||
// #include <execution> // only include if the compiler supports it
|
||||
#include <execution> // only include if the compiler supports it
|
||||
#include <omp.h>
|
||||
|
||||
using namespace std;
|
||||
|
|
@ -94,7 +94,7 @@ int main() {
|
|||
"but my Mac's Clang compiler does not support parallel execution policies.\n";
|
||||
|
||||
// C++17 execution policy version
|
||||
/*
|
||||
|
||||
double t_ep_start = omp_get_wtime();
|
||||
|
||||
auto p = minmax_element(execution::par, v.begin(), v.end());
|
||||
|
|
@ -140,6 +140,6 @@ int main() {
|
|||
<< ", Harmonic mean: " << harm_ep << "\n";
|
||||
cout << "Standard deviation: " << std_ep << "\n";
|
||||
cout << "Elapsed time (s): " << t_ep_end - t_ep_start << "\n";
|
||||
*/
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue