Hi,
This is ravi i have a question like this i have string
"UNDERSTAND" now i want to count the letters how many times
it occures.i.e from the above string the out put should be
like this U-1,N-2,D-2,E-1,R-1,S-1,T-1,A-1.
how can i achieve this
Thnaks in advance for your response ..
Answer Posted / dilip
Actually what i think is take integers from a-z and
initialize each with 0
then take the string & using charAt & equalsIgnoreCase
increment the respaective values & then print the same.....
Is This Answer Correct ? | 0 Yes | 1 No |
Post New Answer View All Answers
Where is the find and replace?
If a method is declared as protected, where may the method be accessed?
Explain wait(), notify() and notifyall() methods of object class ?
What if static is removed from main method?
Write a java program to count the number of words present in a string?
Explain the difference between intermediate and terminal operations in java8?
What does flag mean in java?
What is intern method in java?
What is the order of arraylist in java?
What is null object in java?
How are this() and super() used with constructors in java programming?
When do you get classcastexception?
What is the difference between a break statement and a continue statement?
Explain the difference between protected and default access.
What do you mean by boolean?