Changed iteration counter to a long long unsigned int, because shuffles can get really big. Proof: Try sorting a list of 13.