Can some one work this for me. I can't agree with answers which on my hand.

a) How many ways can one put 9 identically looking sheep into a row of 3 cages, in a way that the leftmost cage holds at most two sheep?

b) in how many ways can a group of 10 different students be divided into one group of 4 and two groups of 3 students?