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

They had given one progam
final HashMap hm=new HashMap();
public void show()
{
hm.put("name",value);
}
in this prg here the final hashtable value can be changed in
put method,its the prg run?

Answer Posted / kr

hash map values can be modified but the hashmap object
cannot be modified
hm.put("name",value); //allowed

hm = new HashMap() // throw error since the object is fianl

Is This Answer Correct ?    19 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between multiple processes and multiple threads?

1213


How do you add an arraylist to an array in java?

984


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

1033


What is data type modifier?

949


What language is an assembler written in?

999


Can we overload destructor in java?

995


Why do I need to declare the type of a variable in java?

1083


What are 5 boolean operators?

1181


Is it necessary for the port addresses to be unique? Explain with reason.

1018


Can list be null in java?

1042


What is the argument in java?

926


Is void a data type in java?

993


Explain what are final variable in java?

1083


what do you mean by classloader?

1092


What is a website container?

956