I would load an array with the skills he doesn't have and then to get a new skill, use random() to index it.
Or if you don't need random, use an array that maintains which skills a player doesn't have, as he gets a new one, set the index to true. When he needs a new skill, cycle through this array and any that are false are assignable.