Final version
fixing all errors