Instead of coding such a script right off, you should be thinking of the design, including detailed ifnormation like the storage system.
This process incldues stuff like "Is this storage method possible with the commands I have available".
With Tcl, you have three memory storage system available to you.
1: Plain Tcl variables, storing strings of text, numbers and anything else.
2: Arrays. These are realy hash lists, but look and operate slightly like arrays.
3: Lists. These are strings of text, formatted in such a way, that multi-word arguments can be stored in one jar, and easily seperated.
One of the other things you need to remember, you want it so that multiple quoestions can be running at the same time.
This requires some form of multi-dimentional storage.
This are of discusion could go on forever, due to the fact, it's not easy to explain some of the topics to new users.Multi-dimentional sotrage.
The ability to have an array of key, value pairs, where the value can be another array.
You can usualy touch on the basics with ease, but some of the tpoics are more advanced, are require an in depth knowledge, or how certain area operate.