uploaded problem 1 - 4 from the PHPSampleExam