changes!
added raii, files and exceptions