added destructor, constructor and made it better!