In an examination, 30% and 35% student's respectively failed in History and Geography with 27% students failed in both the subjects. If the number of students passing the examination is 248 find the total number of students who appeared the examination.