I think ground school is designed to cause this kind of problem.!! It's a lifetime ago now, but i clearly remember how bad i felt at the end of exams. But, it was just another battle to be won. There seemed to be a ministry of obstacles in those days, all focused on the written side of things. I had to treat this as just another test of character. You will have to find this strength in yourself, you are going to need it in your career, and you can't always turn for help.
In those days we took the ATPL after a few years flying, and by then i had three kids, flying the UK's latest jet and the bleak period just a memory.