Use rand(10) to cover all digits 0-9. Fixes #5113