shuffle function added and tested