国产人妻人伦精品_欧美一区二区三区图_亚洲欧洲久久_日韩美女av在线免费观看

合肥生活安徽新聞合肥交通合肥房產生活服務合肥教育合肥招聘合肥旅游文化藝術合肥美食合肥地圖合肥社保合肥醫院企業服務合肥法律

代做00301J 、Java設計編程代寫
代做00301J 、Java設計編程代寫

時間:2024-10-09  來源:合肥網hfw.cc  作者:hfw.cc 我要糾錯



Data Structures and Algorithms Hash Tables 
CRICOS Provide Code: 00301J Page 1 of 3 
 
Note: 
• hashArray stores the key, value and state (used, free, or previously-used) 
of every hashEntry. 
We must store both the key and value since we need to check hashArray 
to tell if there is a collision and we should keep probing until we find the 
right key. 
• put(), hasKey() and get() must take the passed-in key and call hash() to 
convert the key into an integer. This integer is then used as the index for 
hashArray. 
• Java Students: If you use a private inner class for DSAHashEntry, then 
put(DSAHashEntry will need to be private, otherwise it will be public. 
• There are many hash functions in existence, but all hash functions must 
be repeatable (i.e., the same key will always give the same index). A good 
hash function is fast and will distribute keys evenly inside hashArray. 
Hash Tables 
 
Updated: 21st 
July, 2023 
 
Aims 
• To implement a hash table. 
• To make the above hash table automatically resize. 
• To save the hash table and reload it from a file. 
 
Before the Practical 
• Read this practical sheet fully before starting. 
 
Activities 

1. Hash Table Implementation 
Following the lecture slides as a guide, Create DSAHashTable class and a companion 
class called DSAHashEntry to implement a hash table with a simple hash function. Use 
linear probing first since it’s easier to think about, then convert to double-hashing. 
Assume the keys are strings and the values are Objects. 
 Data Structures and Algorithms Hash Tables 
CRICOS Provide Code: 00301J Page 2 of 3  
 
Note: 
• Of course, the latter depends on the distribution of the keys as well, so it’s 
not easy to say what a good hash function will be without knowing the 
keys. 
For the purpose of this practical, just use one of the hash functions from 
the lecture notes. 
• Use linear probing or double-hashing to handle collisions when inserting. 
• hasKey(), get() and remove() will need to use the same approach since 
they also need to find the right item. 
It’s probably a good idea to try make a private find() method that does 
the probing for these three functions and returns the index to use. Use the 
DSAHashEntry state to tell you when to stop probing. 
• Be aware that remove() with probing methods adds the problem that it 
can break probing unless additional measures are taken. 
– In particular, say we added Key1, then Key2 which collides with 
Key1, so we linearly probe and add Key2 to the next entry. 
If we remove Key1, later attempts to get Key2 will fail because Key2 
maps to where Key1 used to be. 
Since it is now null, probing will abort and imply that Key2 doesn’t 
exist. 
– The solution is to use the state filed in DSAHashEntry that tracks 
whether the entry has been used before or not. 
 
2. Resizing a Hash Table 
Modify your DSAHashTable to allow it to resize. There are various ways to determine 
when to and how to resize a hash table. 
 
The simplest way to determine when is to set an upper and lower threshold value 
for the load factor. When the number of elements is outside of this, the put() or 
remove() methods should call resize(size) automatically. 
• Remember, this will be computationally expensive (what is it it in Big-O?), so it is 
important not to set the threshold too low. Also, collisions occur more frequently 
at higher load factors, thus it is equally important to not set the threshold too 
high. Do some research to find "good" values. 
A simple way to resize is to create a new array, then iterate over hashArray (ignoring 
unused and previously used slots) and re-hashing (using put(). 
• To select a suitable size for the new array, you can either use a "look up" table of 
suitable primes or re-calculate a new prime after doubling/halving the previous 
size. 
Test your resize functionality with a small hash table size, just so you know it will 
work when you increase the size of the table. Data Structures and Algorithms Hash Tables 
CRICOS Provide Code: 00301J Page 3 of 3 
 
 
3. File I/O 
To truly test your hash table implementation, you will need a large dataset. Read in 
the RandomNames7000.csv as input to insert values into your hash table. There are some 
duplicates in the file, so your program should be able to handle them. 
 
It is also useful to be able to save the hash table. The save order is not important, 
so just iterate through the keys and values in the order they are stored in the hash 
table and write it to a .csv. 
 
Submission Deliverable 
• Your code are due 2 weeks from your current tutorial session. 
– You will demonstrate your work to your tutors during that session 
– If you have completed the practical earlier, you can demonstrate your work 
during the next session 
• You must submit your code and any test data that you have been using electronically
via Blackboard under the Assessments section before your demonstration. 
– Java students, please do not submit the *.class files 
 
Marking Guide 
Your submission will be marked as follows: 
• [6] Your DSAHashTable and DSAHashEntry are implemented correctly. 
• [4] Your hash function is well thought out and properly implemented. 
This means that it meets at least the first three criteria of a good hash function and 
you can argue that it at least partially meets the last. 
• [5] Your hash table resizes as you put and remove hash entries. 
• [5] You can read in and save .csv files. 
End of Worksheet 

請加QQ:99515681  郵箱:99515681@qq.com   WX:codinghelp

掃一掃在手機打開當前頁
  • 上一篇:FIT5147代寫、代做css/Java編程語言
  • 下一篇:代做CITS2002、C/C++語言程序代寫
  • 無相關信息
    合肥生活資訊

    合肥圖文信息
    流體仿真外包多少錢_專業CFD分析代做_友商科技CAE仿真
    流體仿真外包多少錢_專業CFD分析代做_友商科
    CAE仿真分析代做公司 CFD流體仿真服務 管路流場仿真外包
    CAE仿真分析代做公司 CFD流體仿真服務 管路
    流體CFD仿真分析_代做咨詢服務_Fluent 仿真技術服務
    流體CFD仿真分析_代做咨詢服務_Fluent 仿真
    結構仿真分析服務_CAE代做咨詢外包_剛強度疲勞振動
    結構仿真分析服務_CAE代做咨詢外包_剛強度疲
    流體cfd仿真分析服務 7類仿真分析代做服務40個行業
    流體cfd仿真分析服務 7類仿真分析代做服務4
    超全面的拼多多電商運營技巧,多多開團助手,多多出評軟件徽y1698861
    超全面的拼多多電商運營技巧,多多開團助手
    CAE有限元仿真分析團隊,2026仿真代做咨詢服務平臺
    CAE有限元仿真分析團隊,2026仿真代做咨詢服
    釘釘簽到打卡位置修改神器,2026怎么修改定位在范圍內
    釘釘簽到打卡位置修改神器,2026怎么修改定
  • 短信驗證碼 寵物飼養 十大衛浴品牌排行 suno 豆包網頁版入口 wps 目錄網 排行網

    關于我們 | 打賞支持 | 廣告服務 | 聯系我們 | 網站地圖 | 免責聲明 | 幫助中心 | 友情鏈接 |

    Copyright © 2025 hfw.cc Inc. All Rights Reserved. 合肥網 版權所有
    ICP備06013414號-3 公安備 42010502001045

    国产人妻人伦精品_欧美一区二区三区图_亚洲欧洲久久_日韩美女av在线免费观看
    成人福利视频网| 俺也去精品视频在线观看| 一区二区三区av| 精品国产成人av在线免| 久久手机免费视频| 久久精品免费电影| 久久精品国产成人| 国产精品久久网| 国产精品福利视频| 精品国产中文字幕| 久久99精品久久久久久青青91 | 精品久久久久久久久久中文字幕| 国产精品久久久久久久7电影| 久久成人精品视频| 一区国产精品| 日韩av电影在线观看| 日韩精品一区二区三区色欲av| 热久久这里只有| 狠狠干 狠狠操| 国产精品一区而去| 91九色视频在线| 久久久久久九九九| 国产精品二区在线| 亚洲精品欧美日韩专区| 日韩经典在线视频| 国产欧美在线视频| 国产精品50p| 久久久黄色av| 最新av网址在线观看| 亚洲精品日韩精品| 欧美综合一区第一页| 国产日韩一区二区三区| 91极品视频在线| 国产精品青青草| 中文字幕一区二区三区在线乱码| 日本电影一区二区三区| 国产中文字幕乱人伦在线观看| 91成人免费观看| 国产精品国三级国产av| 色综合影院在线观看| 麻豆中文字幕在线观看| 久久综合九九| 精品久久久久亚洲| 日韩精彩视频| 国产嫩草一区二区三区在线观看| 久久国产日韩欧美| 一区不卡字幕| 国内视频一区二区| 久久久www免费人成黑人精品| 久久的精品视频| 日韩黄色片在线| 99免费视频观看| 国产精品视频网址| 视频一区二区在线| 国产免费一区二区视频| 日韩视频在线免费| 日韩av电影中文字幕| 国产美女精品免费电影| 久久久久久久少妇| 亚洲视频导航| 美女精品国产| 精品久久久91| 日本在线观看一区| 99热一区二区三区| 国产精品成人免费电影| 欧美在线视频观看免费网站| 91.com在线| 亚洲综合视频一区| 国产女人精品视频| 久久天天躁狠狠躁夜夜躁2014 | 好吊色欧美一区二区三区视频 | 欧美,日韩,国产在线| 国产成人福利视频| 亚洲三区视频| 分分操这里只有精品| 国产精品盗摄久久久| 国语精品免费视频| 国产精品女主播| 欧美在线视频a| 久久久久久久中文| 日韩欧美精品在线观看视频| 国产精品97在线| 视频一区国产精品| 国产精品∨欧美精品v日韩精品| 一级黄色免费在线观看| 国产乱码精品一区二区三区卡| 超在线视频97| 国产男女激情视频| 最新欧美日韩亚洲| 99视频在线免费| 天堂v在线视频| 久久综合中文色婷婷| 亚洲a∨一区二区三区| 91国产在线免费观看| 午夜精品在线观看| 国产黄色片免费在线观看| 少妇熟女一区二区| 国产h视频在线播放| 日本中文字幕不卡免费| 日韩视频一区在线| 国精产品一区一区三区有限在线 | 国产精品久久一区二区三区| 欧美亚洲一二三区| 国产精品丝袜视频| 国产又黄又大又粗视频| 色综合天天综合网国产成人网| 国产精品一区二区欧美黑人喷潮水| 伊人天天久久大香线蕉av色| 久无码久无码av无码| 日韩精品福利视频| 国产精品网站视频| 国产午夜福利视频在线观看| 欧美激情视频给我| 久久免费高清视频| 精品欧美日韩| 欧美激情亚洲自拍| 久久综合久久久| 好吊色欧美一区二区三区| 欧美激情在线观看视频| av一区二区三区免费观看| 色视频一区二区三区| 国产精品免费视频久久久| 国产美女视频免费| 日本精品视频网站| 国产精品久久精品视| 91久久在线视频| 欧美亚洲另类在线一区二区三区| 国产精品成人一区| 久久久久国产精品视频| 精品欧美一区二区三区久久久 | 九色成人免费视频| 国产高清av在线播放| 免费在线观看日韩视频| 伊人久久大香线蕉av一区| 国产激情片在线观看| 国产系列第一页| 日本韩国在线不卡| 精品国产一区二区三区久久久久久 | 亚洲一区尤物| 久久久久久久久一区二区| 国产一区免费视频| 午夜精品一区二区三区av| 国产精品日本精品| 久久一区免费| 国产日产精品一区二区三区四区 | 九色自拍视频在线观看| 国产欧美日韩视频一区二区三区| 天堂av在线中文| 国产精品视频1区| 91精品视频免费| 激情综合网婷婷| 天堂一区二区三区| 色综合久久88| 国产精品日韩一区| 国产z一区二区三区| 福利视频一二区| 免费久久久一本精品久久区| 日韩视频第二页| 亚洲xxxx做受欧美| 一区二区三区四区在线视频| 久久精品一区中文字幕| 久久久视频在线| 99久久国产宗和精品1上映| 黄页免费在线观看视频| 日韩免费中文专区| 亚洲不卡中文字幕| 亚洲一卡二卡| 欧美激情视频一区二区| 国产精品高清免费在线观看| 久久精品国产一区二区电影| 国产精品99久久久久久大便| www国产黄色| 国产精品香蕉av| 国产精品综合网站| 国产一区二区免费电影| 狠狠久久综合婷婷不卡| 欧美在线一级视频| 欧美在线一区二区三区四区| 日韩精品一区二区三区不卡| 日本精品免费在线观看| 日本一本a高清免费不卡| 痴汉一区二区三区| 三年中国中文在线观看免费播放| 亚洲高清精品中出| 亚洲精品国产精品久久| 亚洲欧美日韩精品综合在线观看 | 国产综合动作在线观看| 国内精品伊人久久| 欧美日韩亚洲一区二区三区四区 | 欧美专区第一页| 欧美日韩系列| 黄色一级视频在线播放| 精品99在线视频| 免费观看美女裸体网站| 激情婷婷综合网| 美女精品国产| 国产日韩欧美黄色| 国产精品永久免费观看| 99re在线视频上| 久久免费视频1|