100% satisfaction guarantee Immediately available after payment Both online and in PDF No strings attached 4.2 TrustPilot
logo-home
Exam (elaborations)

Data Structures and Algorithms in Java Chapter 11- Hash Tables Test Bank Solution Manual Already Passed

Rating
-
Sold
-
Pages
3
Grade
A+
Uploaded on
14-11-2024
Written in
2024/2025

Data Structures and Algorithms in Java Chapter 11- Hash Tables Test Bank Solution Manual Already Passed What is a hash table? - Answers A data structure that offers very fast insertion and searching. How quick is a hash table? - Answers Insertion and searching taks close to constant time, 0(1) making it essentially instantaneous. What are the advantages to using a hash table? - Answers They are fast and relatively easy to program. If you don't need to visit items in a specific order, and you can predict the size of your data base they are unparalleled in speed and convenience. What are the disadvantages to using a hash table? - Answers They are based on arrays which are difficult to expand after they've been created. For some kinds of hash tables performance may degrade when a table becomes too full, so the programmer should have an fairly accurate idea of how many data items will need to be stored( or be prepared to periodically transfer data to a larger hash table which is time consuming). There is no convenient way to visit items in a hash table in any kind of order(s/a smallest to largest) What is a symbol table? - Answers A symbol table is a data structure that associates a value with a key. It It supports two primary operations: insert (put) a new pair into the table and search for (get) the value associated with a given key. The symbol table holds all the variable and function names made up by the programmer, along with the address where they can be found in memory. What is the ASCII code? - Answers Its a way to represent individual characters as numbers. a is 97, b is 98, c is 99 and so on. It runs from 0 to 255 to accomodate capitals and punctuation. In an ordinary multi-digit number, each digit-position represents a value: - Answers 10 times as big as the position to it;s right. So 1234 really means 1*1000 + 2*100 + 3*10 + 4*1. ( OR writing the multipliers as powers of 10 1*10^3 + 2*10^2 + 3*10^1 + 4*10^0 How would you convert the word "money" into a multi-digit number? - Answers 1. Convert each digit into a number. I can use my own code instead of ASCII. So I would set a=1, b=2 and so on. I would set blank = 0 to accomodate for for a space giving my 27 characters. 2. Next I would multiply wach number by the appropriate power of 27 and add the results. This process generates a unique number for every potential word. An array can handle a number/word this small. What is the % operator in java? - Answers The modulo operator finds the remainder when one number is divided by another. What is a hash function? - Answers It hashes (converts) a number in a large range into a number in a smaller range. The smaller range corresponds to the index numbers in an array. What is a hash table? - Answers An array into which data is inserted using a hash function. How does a hash function work? - Answers 1. We convert a word into a huge number by multiplying each character in the word by an appropriate power of 27 and set it equal to hudgeNumber 2. Using the modulo operator (%), we squeeze the resulting huge range of numbers into a range about twice as big

Show more Read less
Institution
Data Structures And Algorithms In Java Chapter 11
Course
Data Structures and Algorithms in Java Chapter 11








Whoops! We can’t load your doc right now. Try again or contact support.

Written for

Institution
Data Structures and Algorithms in Java Chapter 11
Course
Data Structures and Algorithms in Java Chapter 11

Document information

Uploaded on
November 14, 2024
Number of pages
3
Written in
2024/2025
Type
Exam (elaborations)
Contains
Questions & answers

Subjects

Content preview

Data Structures and Algorithms in Java Chapter 11- Hash Tables Test Bank Solution Manual Already
Passed

What is a hash table? - Answers A data structure that offers very fast insertion and searching.

How quick is a hash table? - Answers Insertion and searching taks close to constant time, 0(1) making it
essentially instantaneous.

What are the advantages to using a hash table? - Answers They are fast and relatively easy to program.
If you don't need to visit items in a specific order, and you can predict the size of your data base they are
unparalleled in speed and convenience.

What are the disadvantages to using a hash table? - Answers They are based on arrays which are difficult
to expand after they've been created. For some kinds of hash tables performance may degrade when a
table becomes too full, so the programmer should have an fairly accurate idea of how many data items
will need to be stored( or be prepared to periodically transfer data to a larger hash table which is time
consuming). There is no convenient way to visit items in a hash table in any kind of order(s/a smallest to
largest)

What is a symbol table? - Answers A symbol table is a data structure that associates a value with a key. It
It supports two primary operations: insert (put) a new pair into the table and search for (get) the value
associated with a given key. The symbol table holds all the variable and function names made up by the
programmer, along with the address where they can be found in memory.

What is the ASCII code? - Answers Its a way to represent individual characters as numbers. a is 97, b is
98, c is 99 and so on. It runs from 0 to 255 to accomodate capitals and punctuation.

In an ordinary multi-digit number, each digit-position represents a value: - Answers 10 times as big as
the position to it;s right. So 1234 really means 1*1000 + 2*100 + 3*10 + 4*1. ( OR writing the multipliers
as powers of 10 1*10^3 + 2*10^2 + 3*10^1 + 4*10^0

How would you convert the word "money" into a multi-digit number? - Answers 1. Convert each digit
into a number. I can use my own code instead of ASCII. So I would set a=1, b=2 and so on. I would set
blank = 0 to accomodate for for a space giving my 27 characters.

2. Next I would multiply wach number by the appropriate power of 27 and add the results.

This process generates a unique number for every potential word. An array can handle a number/word
this small.

What is the % operator in java? - Answers The modulo operator finds the remainder when one number
is divided by another.

What is a hash function? - Answers It hashes (converts) a number in a large range into a number in a
smaller range. The smaller range corresponds to the index numbers in an array.

Get to know the seller

Seller avatar
Reputation scores are based on the amount of documents a seller has sold for a fee and the reviews they have received for those documents. There are three levels: Bronze, Silver and Gold. The better the reputation, the more your can rely on the quality of the sellers work.
TutorJosh Chamberlain College Of Nursing
View profile
Follow You need to be logged in order to follow users or courses
Sold
332
Member since
1 year
Number of followers
16
Documents
28211
Last sold
1 day ago
Tutor Joshua

Here You will find all Documents and Package Deals Offered By Tutor Joshua.

3.6

53 reviews

5
18
4
14
3
12
2
0
1
9

Recently viewed by you

Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Frequently asked questions