Everyone thinks I'm smart but I feel like a fraud.
Is this in response to that guy complimenting you on your intelligence?
I've compared my grades with his and mine are really bad.
While we all have our self-doubts from time to time, they shouldn't stop you from accepting a compliment when given one. If someone considers you to be smart, you should take that as a sincere statement. If you struggle with thoughts of imposter syndrome you should talk with a therapist and try to work on your self-confidence.
Fuck you, I'm going to ignore that and  just go and let my parents I got a bad grade on my math exam. At least it won't be a lie.
I understand that you're frustrated and struggling to accept a genuine compliment, but lashing out and criticizing yourself isn't helpful. Perhaps you could set goals and find a tutor who could help you out with your exams, as you truly are quite intelligent.