Answered step by step
Verified Expert Solution
Question
1 Approved Answer
I need help defining a class in C++ that acts like a python dictionary. I need to be able to add keys-values to an already
I need help defining a class in C++ that acts like a python dictionary. I need to be able to add keys-values to an already existing dictionary. For example
id= {'sam':75, 'robert':09907, 'timmmy',95453, 'samuel',5333)}.
i want to create a class in which i can do
id.add("samuel', 8439922) and it adds it to the dictionary. i want to implement this with using vectors to store the pairs.
I need to do this without using any features like maps, every thing has to be made from scratch.
edit: does not need to be generic, can be with strings and ints
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started