During my master’s degree i did. I studied one semester in france, and found it incredibly hard with the language, and literally failed 7 out of 10 exams I took! Thankfully the teachers were very nice, and I was able to retake 4 of them and passed the course, but had I not spent 2 months studying myself to death to pass the re-exams I would have failed my masters and wasted 2 years, not nice!
So yea, it happens, move on but change your study habits if it does happens if you want a different result, takes work to make good grades!
I had some very mixed report cards. My physics teacher gave me an A but also called me a rude word. most of mine were a mix of A’s and fails without much inbetween so im not sure if that counts as good or not really. My second school was even worse but I did great in college!