In this problem, we will create a new data type. Each data point consists of a "key" and "data". Examples of data points

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899604
Joined: Mon Aug 02, 2021 8:13 am

In this problem, we will create a new data type. Each data point consists of a "key" and "data". Examples of data points

Post by answerhappygod »

In This Problem We Will Create A New Data Type Each Data Point Consists Of A Key And Data Examples Of Data Points 1
In This Problem We Will Create A New Data Type Each Data Point Consists Of A Key And Data Examples Of Data Points 1 (38.31 KiB) Viewed 46 times
In this problem, we will create a new data type. Each data point consists of a "key" and "data". Examples of data points might be name: Alice phone: 215-204-9999 If both of these data points are stored in a data structure, then we could have a function that works like this: data structure ==>get_data("name") returns Alice Our data structure will also allow us to implement nested data. For example: name: (first: Alice}, {last: Smith} } address: {{street: 123 Main St.}, {city: Anytown}, {state: PA} } In this example, we would be able to access data using something like: data structure ==> get_data ("address") ==> get..data("state") returns PA Design a C++ data structure to handle this data type. You don't have to write any code if you don't want to. However, you should be as specific as possible about the variable types and class or classes you use. For each class you propose, describe both the variables and the functions (methods) that it contains. Diagrams are not required but may be helpful. Be sure to describe how the get.data function works with your data structure.
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply