American Express Interview Question

check if the string contain duplicate letter