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 is hash table

Answer Posted / kumaresh

1.Hashtable is a class which falls into System.Collections
namespace.
you can create object for hashtable. For example,
Hashtable hash = new Hashtable();

2.Key and value should be added to hashtable. For example,
hash.Add(1,"God");
hash.Add(2,"Human");

3.The key, value will be sorted automatically based on the
Hashcode generated[this operation is taken care by CLR].

4.GetHashCode() method is used to get the generated hashcode

5.While retrieving the hashtable values, you can use the
key tp retrieve the values. For example
foreach (DictionaryEntry item in hashTable)
{
Console.WriteLine("Key is {0}, Value is
{1}", item.Key,item.Value);
}
NOTE: if you add the same key into the hastable, it will
not throw any compliation error, but during runtime, it
will throw "ArgumentException" error.

Is This Answer Correct ?    19 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is an entity-relationship diagram (erd)?

1213


What is temporal data type?

921


What is primary key index?

979


What is difference between view and materialized view?

937


We need to perform what steps in the following order to work with a cursor?

1218


List the types of recovery model available in sql server?

928


What is replace and stuff function in sql server?

1066


what is a transaction? : Sql server database administration

992


How many types of local tables are there in sql server?

930


How to download and install the scaled-down database adventureworkslt?

992


What is an sql server agent?

1064


While using a cursor, how can you differentiate between a deleted row and a row that has been inserted with null data values?

1043


Explain the difference between clustered and non-clustered index?

923


What are rows and columns?

1019


How do you identify a foreign key?

1024