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

Why java is free from garbage values??

Answer Posted / mihirdash

first take an example of c/c++,here the decaration and initialization is the programmer responsibility if not it gives the garbage value.but in java every thing is taken by jvm.we can declare any number of variable but it should be initialized.otherwise if we are going to use the uninitialized varibles the java compiler gives error.so there is no garbage value in java.
and if youu are created a object the keyword new is assigned default value during crreation of object

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How do you implement polymorphism in our day to day life?

3224


What is the difference between math floor and math round?

1028


What are constants and how to create constants in java?

978


What is OOP Language?

1065


What is a marker interface?

1148


What does n mean in java?

959


What is initial size of arraylist in java?

1044


Why we cannot override static method?

1050


Can you override static methods?

951


What is difference between null and void?

964


Can we store variables in local blocks?

1343


How do you define a method?

974


What is difference between local variable and global variable?

1007


Why is flag used in java?

1060


Explain OOPs concept.

1076