You can write a program that will obtain user input and then examine this text to see whether it contains duplicates. If the verification fails, you may elect to loop back and prompt for the same input again.
>there no pint telling me how it works, i need codes
If there's no point in us telling you how it works, then you aren't capable of writing even the simplest code, so giving you code is equally pointless.
He was doomed from the start. An ineffective subject line.... Please what? I hope he takes the chance to actually learn from this, and not to merely copy things. I also hope that no one gives him the easy way out.