Added a randomize method