code for naughty or nice machine - current version