I'd hazard a guess that this had less to do with java and more to do with your lack of c experience. collections in c is a solved problem, there are numerous libraries (glib, for example) out there that are all similar to Java's collections.
C++ has stl with many of the same collections, and if you want to use auto_ptr, you don't even need to remember to call delete.
I am not saying there are not productivity gains to be had from using java, but as in this case, it typically comes from not having the relevant experience elsewhere.