Failure is not the end of life. Failing an exam doesn't make you any less intelligent or less capable of achieving success in life than those who got better results. Just think that the failure you had in exams was just another step towards success. You can definitely score good marks in the exam, next time.