Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

count value a to b character javascript

 const recorrences = ['a', 'b', 'c', 'a', 'b','a']
                .map(i => !!~i.indexOf('a'))
                .filter(i => i)
                .length;
console.log(`recorrences ${recorrences}`) 
//recorrences 3
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #count #character #javascript
ADD COMMENT
Topic
Name
4+1 =