Welcome to the CSC Q&A.
Get help and give help!
Write great code!
It is our choices... that show what we truly are, far more than our abilities.

Categories

+5 votes

Is there a command you can use to count specific characters in a string?

asked in CSC212_Spring2019 by (527 points)

1 Answer

+2 votes

The String class doesn't have a method to do that. You'll need to loop through the index values of the string examining each character.

answered by (3k points)
...