C++ Help - How can i remove the class object from the following code? I wanna rewrite this code using only array. Please help!
#include
An array is an array of something. In this case you have an array of class objects. I am not sure what you mean because of this.
I wanna rewrite this using only Array. Could you help?
Look at all the data stored in the class. Write an array for each element in the class. So for each of these variables: int id; string name, designation; float salary; You need to make an array.
You mean something like this: http://paste.ubuntu.com/7031685/ But i got so many errors. and its not working. Please help me out here. Thanks,
I think associative arrays are implemented as maps in C++ http://www.cplusplus.com/reference/map/map/ With that you can store the values in an array with logical keys to reference them
@seandisanti Thanks for your replay. I'm not a C++ programmer or something. I'm trying to help out someone. Can you please help me converting the first program with Array only. Please?...
The first code this one => http://paste.ubuntu.com/6998646/ works fine. But i would like to have without class. Use only Array and strings. Please help..
I'm actually already actively writing solutions to a problem set for someone else, and was just popping in to help out where a quick explanation would be help enough to get going the right direction. This one is a pretty easy issue, I promise, check out this example of map usage: http://www.yolinux.com/TUTORIALS/CppStlMultiMap.html
Join our real-time social learning platform and learn together with your friends!