What is the difference between Hash Table and Arrays?

Answer Posted / ravi

a) Hash table store data as name,value pair. while in array
only value is store.

b) to access value from hash table, you need to pass name.
while in array, to access value , you need to pass index number.

c) you can store different type of data in hash table, say
int,string etc. while in array you can store only similar
type of data.

Is This Answer Correct ?    4 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is a games console a computer?

680


What are the 3 elements of delegation?

715


What do you mean by saying a "struct is a value type"?

692


What is datetime parse in c#?

708


What type is string in c#?

643


Can you pass value types by reference to a method?

708


What is difference between constants and readonly in c#?

749


Difference between abstract classes and interfaces

741


What is expression c#?

693


Is dll a library?

678


What is the use of functional interface?

688


What is callback delegate in c#?

641


What is use of FormBoarderStyle Propertie

699


Can a class be protected in c#?

665


What is expression tree with example?

656