Using a way better AppleScript

Script found on StackOverflow: http://stackoverflow.com/questions/14674517/how-to-set-itunes-11-in-shuffle-or-repeat-mode-via-applescript