Hi to all, I'm trying to redirect the [] from a class to a property of that class
Class Myclass
{
bool myBool;
string myString;
map<int,string> myMap;
}
I wanted to do somethin like:
Myclass a;
a[0] = "hello world"
and it actually would set myMap[0] to hello world".
and
cout << a[0]
to print "hello world";
Possible??
Thank you in advance!