Find Jobs
Hire Freelancers

The purpose of this project is to familiarize with the map abstract data type (ADT) and its several implementations. Second, it is to reinforce the concepts of interfaces, inheritance, polymorphism, and the idea of empirical analysis.

$10-30 USD

已关闭
已发布超过 8 年前

$10-30 USD

货到付款
In the project files folder you will find the Map.h file as well as several skeleton files. Map.h defines the interfaces for each of the template classes you will be implementing in this project. To complete this project you must implement the following three template classes: • HashMap • TreeMap • SearchTable Each of the above template classes must extend the given abstract Map class. For each of the above classes you must implement the “Big-3” (Copy constructor, overloaded assignment operator, and destructor) in addition to the below requirements. HashMap This class will implement the map ADT by using a hash table. You may use either separate chaining or open addressing to resolve hash collisions. If you choose open addressing, you must use linear probing. If you you use separate chaining you are free to use the ArrayList class or the LinkedList class from project 1. 2 n Put Erase Find Size 1 0 0 0 0 1001 0 0.000999001 0.001998 0 . . . . . . . . . . . . . . . 9001 0 0.0885457 0 0.0433285 Table 1: CSV File Structure TreeMap This class will implement the map ADT by using a binary search tree. The bi- nary search tree can be implemented in a separate file (BinarySearchTree.h). This class will contain a private data member for the binary search tree which is used to implement the methods of TreeMap. SearchTable This class will implement the map ADT by using a sorted search table and the binary search algorithm. A private function Sort for sorting the array using a sorting method of your choice must be implemented, as well as a method Search which implements the binary search algorithm. Once these classes have been implemented, use the [login to view URL] provided file to generate a CSV file of timing results. The timing results for HashMap, TreeMap, and SearchTable will be found in [login to view URL], [login to view URL], and [login to view URL] respectively. The structure for both of the CSV files is shown in Table 1. In the table, the n column denotes the input size and the next four columns give the average run-time in ms of the given operations. Plot these results using software like LATEX, Excel, Matlab, Mathematica, GNU Plot, etc. Given these plots, answer the following questions: 1. What are the big-O run-times of the four Map operations for HashMap? Do your empirical results agree with this? Why or why not? 2. What are the big-O run-times of the four Map operations for TreeMap? 3 Do your empirical results agree with this? Why or why not? 3. What are the big-O run-times of the four Map operations for SearchTable? Do your empirical results agree with this? Why or why not? 4. Draw a class diagram of the classes in this project. Label the inheri- tance relationships as either being has-a or is-a. Deliverables These are the following files required for this assignment: 1. HashMap.h 2. [login to view URL] (optional) 3. TreeMap.h 4. [login to view URL] (optional) 5. SearchTable.h 6. [login to view URL] (optional) 7. BinarySearchTree.h (optional) 8. [login to view URL] (optional) 9. [login to view URL] In the list of files above, the .cpp files are optional because the function implementations can be placed directly inside the .h files. Due to the way C++ implements templates, the function implementations must be visible when compiling the template class. This can be accomplished by either by providing the implementation inside the class itself, or by including the .cpp at the end of the .h file. If you do not have .cpp files, your .h files must contain the function implementations. The [login to view URL] file will contain the following sections: 1. Plots 2. Questions 4 3. Source Code Combine all of the above deliverable files into one zip file and upload it to portal by the due date. Clearly specify your name in the report.
项目 ID: 9053749

关于此项目

5提案
远程项目
活跃8 年前

想赚点钱吗?

在Freelancer上竞价的好处

设定您的预算和时间范围
为您的工作获得报酬
简要概述您的提案
免费注册和竞标工作
5威客以平均价$112 USD来参与此工作竞价
用户头像
A proposal has not yet been provided
$252 USD 在3天之内
4.9 (98条评论)
7.4
7.4
用户头像
I am very proficient in c, c++. I have 16 years c++ developing experience now, and I have worked for 6 years. My work is online game developing, and mainly focus on server side, the language is c++ under linux. I used c++ to make many great projects, for example, I made the tools which can convert java files to c++ scripts which has the same effect, of course garbage collection included. I also made our own mobile game using c++, I even can show you the demo of client. Trust me, please let expert help you.
$80 USD 在1天之内
4.9 (142条评论)
7.0
7.0
用户头像
A proposal has not yet been provided
$133 USD 在10天之内
4.9 (2条评论)
2.7
2.7
用户头像
i can do it in just 1 day... i'm C++ developer with 2+ year experience! CONTACT ME A.S.A.P for QUALiTY ASSURED WORK!
$50 USD 在1天之内
5.0 (4条评论)
2.3
2.3

关于客户

UNITED STATES的国旗
United States
0.0
0
会员自12月 6, 2015起

客户认证

谢谢!我们已通过电子邮件向您发送了索取免费积分的链接。
发送电子邮件时出现问题。请再试一次。
已注册用户 发布工作总数
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
加载预览
授予地理位置权限。
您的登录会话已过期而且您已经登出,请再次登录。