Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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


Please Help Members By Posting Answers For Below Questions

What is the symbol for average?

975


What is ph and buffers?

937


What is difference between checked and unchecked exception in java?

957


Why wait(),notify(),notifyAll() methods defined in Object class althought we are using in only threads.

2757


How do I convert a string to an int in java?

1011


What are voids?

917


Compare overloading and overriding?

954


What is a conditional statement explain with example?

961


we have syntax like for(int var : arrayName) this syntax is to find whether a number is in the array or not.but i want to know how to find that number's location.

1985


Why do we use variables?

926


Can we have two main methods in a java class?

990


How much is a java license?

869


What is module in project?

895


What is nextint java?

975


What are triggers in DB? Explain their types. How do they work?

1034