Missed the exam despite having to provide a medical certificate, what should I do?

I was supposed to write a chemistry paper today, but I studied until so late in the evening that I overslept and missed the entire exam. However, I actually have to provide a medical certificate! Now I'm afraid that my teacher will automatically give me a 6 because I don't have a certificate for the…