Write program to print Hello World and print each character
address in that string and print how many times each
character is in that string?
Ex: H: 0 & 1
e:1 & 1
l :2,3,8 & 3
o:4,6 & 2
w:5 & 1
r: 7 & 1
d 9 & 1
Answer Posted / noor
Little change in the code
add this for loop
for (int x = i - 1; x >= 0; x--)
instead of
for (int x = i - 1; x > 0; x--)
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is considered an anti pattern?
How do you sort in descending order in java using collections sort?
Can we define package statement after import statement in java?
Write a java program to print fibonacci series?
What is the relationship between clipping and repainting under awt?
What lambda means?
what do you understand by synchronization? : Java thread
What is the default access specifier for variables and methods of a class?
What is predicate in java?
What are the different tags provided in jstl?
What is a copy constructor in java?
What function extracts specified characters from a string?
What are pass by reference and pass by value?
which one is more efficient int x; 1. if(x==null) 2.if(null==x) state which one either 1 or 2?
Why do we need hashset in java?