fixed the first problem