28/// An implementation of the bogo-sort[1] algorithm, in STL-style.
29/**
30 Apologies to all members of the C++ standards community for this perversion.
31 This algorithm should never be used in any code, apart from as an example of easy it is to create an apparently innocuous algorithm which can have an exceptionally bad order.
32
33 I quote an edited excerpt of a discussion on the ACCU-General mailing list regarding this implementation:
34 "The quest for perversity was clearly at odds with the quest for beauty. I think perversity wins out in this case.
35
36 And yes, you're a very bad man. How about compounding your badness and just writing this little gem up for Overload or blogging it so that it becomes immortalised and searchable? >:->
37
38 Kevlin [Henney]"
39
40 \param first The start of the input range.
41 \param last The end of the input range.
42 \param comp The comparator to be used to compare two values within the range.
43
44 Complexity: the *truly* excessive and exorbitant: O(N*N!+N*N)=O(N*N!), c.f. with O(nlog(n)) of std::sort().