+ 2
[SOLVED]what does length()==7 mean?
I'm new thanks for helping me 😊
10 Respuestas
+ 5
Ok, so a.length is exactly what it looks like - the length of a string. In other words, it's a number of characters that the string contains.
+ 3
hamid It doesn't. It just returns the length. You have to use some other function to check for the number of occurrences.
+ 3
I am not really sure if there is a .count method in Java just like that.
But you can use the following - while iterating through the string, try to find a difference between a.length() and a.replace(<char>, "").length()
+ 2
Kuba Siekierzyński I wanted to know how it distinguishes a character is repeating ?
+ 2
Kuba Siekierzyński
That's right thanks for that
I should pay more attention.
but which method will distinguishe characters repetition??
+ 1
hamid Please be more specific. It could mean anything.
0
thank you so much 👍
0
thanks
0
html / js : htmlElement.length