Buffon
asked on
standard template libraries
I need to know how with STL I can use associative arrays, please provide code examples.
ASKER
I saw this declaration:
typedef map<string,string> line;
as I understand it, it declares something like hashtable (value + key), so in declaration first "string" represents key or value?
typedef map<string,string> line;
as I understand it, it declares something like hashtable (value + key), so in declaration first "string" represents key or value?
>as I understand it, it declares something like hashtable (value + key), so in declaration first "string"
>represents key or value?
No, there is an non-standard hash_map<> collection class in some STL implementations.
Map usually have some internal implementation of tree (binary, balanced, etc....) but there is no a rule about this. Anyway, this is transparent to the user.
>represents key or value?
No, there is an non-standard hash_map<> collection class in some STL implementations.
Map usually have some internal implementation of tree (binary, balanced, etc....) but there is no a rule about this. Anyway, this is transparent to the user.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
https://www.experts-exchange.com/questions/20566432/Associative-array-of-string.html