We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent df08be5 commit d36bd0aCopy full SHA for d36bd0a
Sprint-3/2-practice-tdd/count.js
@@ -1,7 +1,7 @@
1
function countChar(stringOfCharacters, findCharacter) {
2
const totalCount=stringOfCharacters.split("");
3
-Count=0
4
-for(i=0; i<totalCount.length; i++){
+let count=0
+for(let i=0; i<totalCount.length; i++){
5
if(totalCount[i]===findCharacter){
6
count++
7
}
0 commit comments