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 integer overflows and underflows and how to handle
them?

Answer Posted / ramesh kumar

byte b = (byte)250;

Here I assinged the value to b more than the positive range
of byte. So, It leads to overflow and we won't get any
error in compile time or run time.

But some unexpected value will be stored into b. i.e b = -
6. This will affect your logic.

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between double and float variables in java?

1082


What is variable length arguments in java?

909


what is instanceof operator used in java?

971


Differences between C and Java?

1116


What are the super most classes for all the streams?

2397


How do you create immutable object in java?

988


How will you load a specific locale?

925


Which of the following is not an isolation level in the JDBC

2074


What happens if constructor is private?

972


What is difference between final and immutable?

1076


What classes of exceptions may be thrown by a throw statement?

908


What happens if I remove static from main method?

969


What are keywords give examples?

998


How do you define a set in java?

944


How does hashset works in java?

1006