Reagan is the objective correct answer. The question is to what degree his and Carter's policies influenced it.
I agree that Reagan is the right answer but it's not like their policies were polar opposites, they had a similar approach in that they moved toward deregulation and tax reform, but Reagan took it to a further extent than Carter did. Probably because Carter being a Southern conservative Democrat and Washington outsider put him at odds with the liberal Democrats in Congress. Carter and Reagan even shared the same Fed Chairman, Paul Volcker.
I think basically Reagan had the benefit of Carter's presidency being a magnet for disaster. It seems to be that point in history where no matter who had been President they would have lost the election, kind of like 1932 or 2008.