Is gardening as a whole a hit and miss when trying to get a good harvest? - eviltoast

What I mean is, do you get better crop yield in one year and a year later you don’t get much depending on how bad or good the season was?

I’m at zone 7 UK if that helps. We’ve just started to try gardening this year and the summer season has been scorching most of the time and with autumn rolling in it’s still fairly warm but not sunny.