Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- cout << "ПИРАМИДАЛЬНЯ СОРТИРОВКА" << endl;
- for (int i = 0; i < N; i++) {
- b[i] = rand() % 100 - 50;
- }
- for (int i = 0; i < 100; i++) {
- for (int i = 0; i < N; i++) {
- a[i] = b[i];
- }
- auto start = chrono::high_resolution_clock::now();
- heapSort(b, N);
- auto end = chrono::high_resolution_clock::now();
- chrono::duration<double> duration = end - start;
- k += duration.count() / N;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement