The jargon file has a nice entry on this, bogo-sort. I suppose their code would look like:
Then again, I've never used the Quantum functions-- and yes, I know you can't 'destroy the Universe' just by using DConway's modules... yet.use Quantum::Superpositions qw(any); return any(splatterSort(@list) and isSorted(@list));
In reply to Re: Making bubble sort look good
by Anonymous Monk
in thread Making bubble sort look good
by RMGir
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |