Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

js character certain count

var str = "Hello Lewes";
var ch = 'e';
 
var count = str.split("e").length - 1;
console.log(count);
 
/*
    Output: 3
*/
Source by www.techiedelight.com #
 
PREVIOUS NEXT
Tagged: #js #character #count
ADD COMMENT
Topic
Name
5+4 =