algorithms count

Solutions on MaxInterview for algorithms count by the best coders in the world

showing results for - "algorithms count"
François
28 Jan 2020
1public int countLetterB(String s) {
2    int count = 0;
3    for (char c: s.toCharArray()) {
4        if (c == 'b') {
5            count++;
6        }
7    }
8    return count;
9}
queries leading to this page
counting algorithmsalgorithms count