four persons,A,B,C,D form a committee.One is to be president,one is to secretary, one is to be finance secretary and one should be registrar. In how many ways can these posts be asigned?

Answer given is 4!

But how can this bepossible as as there will be many ways in which each person will have more than one post,and in some ways all the posts will go to one person.

Then how to solve this problem.