Question d’entretien chez Vernost

Write a program in javascript to find duplicate in a string