edited readme and made code more readable