updated and fixed mistakes