Sfoglia il codice sorgente

back to selection sort, no partition

master
Ludovic 'Archivist' Lagouardette 3 anni fa
parent
commit
5041266ecc
2 ha cambiato i file con 3 aggiunte e 3 eliminazioni
  1. +2
    -2
      include/gp/algorithms/partition.hpp
  2. +1
    -1
      include/gp/algorithms/sort.hpp

+ 2
- 2
include/gp/algorithms/partition.hpp Vedi File

@ -36,9 +36,9 @@ namespace gp {
return first;
}
/**
template<typename it_t, typename pred>
it_t partition(it_t first, it_t last, pred predicate = pred{}) {
return gp::hoare_partition(first, last, predicate);
}
}**/
}

+ 1
- 1
include/gp/algorithms/sort.hpp Vedi File

@ -70,6 +70,6 @@ namespace gp {
template<typename it_t, typename pred>
void sort(it_t first, it_t last, pred predicate = pred{}) {
return gp::__details::bubble_sort(first, last, predicate);
return gp::__details::selection_sort(first, last, predicate);
}
}

Caricamento…
Annulla
Salva