Use app×
Join Bloom Tuition
One on One Online Tuition
JEE MAIN 2025 Foundation Course
NEET 2025 Foundation Course
CLASS 12 FOUNDATION COURSE
CLASS 10 FOUNDATION COURSE
CLASS 9 FOUNDATION COURSE
CLASS 8 FOUNDATION COURSE
0 votes
12.7k views
in Computer by (69.2k points)

The following values are to be stored in a Hash-Table: 

25, 42, 96, 101, 102, 162, 197, 201

Use the Division method of Hashing with a table size of 11. Use the sequential method for resolving collision. 

1 Answer

+1 vote
by (69.8k points)
selected by
 
Best answer

The given values are as follows: - 

25 42 96 101 102 162 197 201

Table size is = 11 

Division method of Hashing: -

H (k) = {Hash address range from 0 to m-1. Key (mod) table-size.} 

H (25)= 3 

H (42) = 9 

H (96) = 8 

H (101) = 2 

H (102) = 3 

H (162) = 8 

H (197) =10 

H (201) = 3

The Hash table is as follows

Hash [0] = [197] 

Hash [1] = [NULL] 

Hash [2] = [101]  

Hash [3] = [25]  Collision Occurred

Hash [4] = [102]  Inserted in next available slot

Hash [5] = [201] 

Hash [6] = [NULL] 

Hash [7] = [NULL] 

Hash [8] = [96] 

Hash [9] = [42] 

Hash [10] = [162]

Welcome to Sarthaks eConnect: A unique platform where students can interact with teachers/experts/students to get solutions to their queries. Students (upto class 10+2) preparing for All Government Exams, CBSE Board Exam, ICSE Board Exam, State Board Exam, JEE (Mains+Advance) and NEET can ask questions from any subject and get quick answers by subject teachers/ experts/mentors/students.

Categories

...