Fourth homework for PHP course