arul : if you are gonna do it in C-style, it is better to use malloc rather than calloc..
anyway, C is annoying, go with C++ 
__________________
"Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it."
|