home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The C Users' Group Library 1994 August
/
wc-cdrom-cusersgrouplibrary-1994-08.iso
/
listings
/
v_11_11
/
splash
/
assoc.cpp
next >
Wrap
Text File
|
1993-01-15
|
560b
|
25 lines
#ifdef TESTASSOC
#include <iostream.h>
#include "splash.h"
#include "assoc.h"
main()
{
Assoc<int> a;
a("one")= 1; a("two")= 2; a("three")= 3;
cout << a << endl;
cout << "Keys:" << endl << a.keys() << endl;
cout << "Values:" << endl << a.values() << endl;
cout << "a.isin(\"three\")= " << a.isin("three") << endl;
cout << "a.isin(\"four\")= " << a.isin("four") << endl;
int t= a.adelete("two");
cout << "a.adelete(\"two\") returns: " << t << ", a= " << endl << a << endl;
}
#endif