Hello and welcome to LinuxQuestions,
This question sounds a lot like homework. If it is, then you'll probably get very little response to it, since the rules indicate that LQ users are reluctant to do your homework for you. You'll learn a lot more doing/trying yourself.
On the other hand, if you post what you have done and where it fails, then I'm sure someone will point you in the right direction and/or indicate your errors.