so i had this problem on codewars, where i have to find same letters in a passed in string and shall return the letters that are twice or more often inside that string. Here is my attempt which threw out an error:
function duplicateCount(text){
text.split('')
for(var i = 0, i < text.length, i++) {
for(var j = 1, j < text.length + 1, j++)
if(text[j] = text[i]) {
return text[i]
}
else return
}
//...
}
i have very little expierience so dont be to harsh lmao