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...

What are the types of loops in Java, and how are they used?

Answer Posted / hr@tgksolutions.com

• In Java, for loops are used to repeatedly run statements for a specified number of times. When a programmer knows how many times to run a statement, they use a for loop.
•When some statements must run continuously until a condition is met, the while loop can be helpful. Before statements are executed in while loops, the condition is checked.
•With the exception of checking the condition after a block of statements has been executed, the do while loop is identical to the while loop. Do while loop statements should also run at least once.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Difference between nested and inner classes ?

1189


What is the synonym of procedure?

1203


Give reasons supporting that string is immutable.

999


Is 0 true or false?

1048


What is argument in java?

1058


What is internal variable?

1067


How to stop a thread in java? Explain about sleep () method in a thread?

1069


What is a java list?

1157


What are dot operator queries?

1153


What is the difference between the direct buffer and non-direct buffer in java?

1081


Which is bigger float or double?

1026


What is a type parameter in java?

1062


Why do we need wrapper classes?

1118


Which methods are used during serialization and deserialization process?

1040


Can we have more than one package statement in the source file?

1110