Exams are the least bad means of grading students.  True, a pupil may mess up on the day, and not show his real capacity.  And, yes, a test crammed into a short period of time, rather than assessments carried out over a longer one, favours some temperaments over others.  Those who can adapt to sudden death penalty shoot-outs win out, as it were, over those more comfortable with attritionally climbing the league table.

Some would prefer teacher assessment.  But whether these critics are right or wrong, exams are a known feature of our educational landscape.  They have, in a rough and ready way, popular consent.  But a computer’s algorithm alone was never likely to possess the missing authority of an examiner’s pen – especially when it tampers with some 40 per cent of suggested grades.

In a nutshell, last week’s A-level results, and this week’s coming GCSE ones, pit different unfairnesses against each other.  Nick Gibb’s article defending the Government on this site last week viewed justice from the top down.  Simply awarding pupils their teacher-assessed grade, he argued, would reward schools who have inflated their suggestions at the expense of those who did not, and unfairly advantage this year’s students at the expense of next year’s.

Gibb was right.  But, as his piece implicitly acknowledged, justice must also be viewed from the bottom up.  And the sum of the matter is that, at a macro level, the algorithm did what it was meant to do – that’s to say, balance allowing grades to rise slightly while also keeping their inflation in check.  But what works for the macro doesn’t necessarily work for the micro.

What the algorithm produced last week is rather like a picture that looks flawless from a distance but, when viewed close up, turns out to be marred by blotches, chips, and reworkings.  Perhaps other variants would have worked better.  But it seems to us that the algorithmic logic of standardisation was always likely to produce individual and collective injustices, as it crunched its way through the numbers.

It was therefore stupifyingly insensitive for the Education Department, in a rebuttal document published last week, to say that “in 96 per cent of cases grades were the same as submitted by teachers or were just one grade different”.  A single grade can be the sword that separates a pupil from the University place he had been conditionally offered.  And if he isn’t going on to higher education, a lower grade could imperil his career prospects.

In the absence of exams, and the legitimacy that they supply, August thunder-clouds were always going to gather for Gibb and Gavin Williamson.  In one sense, this makes them and in another mars them.  It makes them, in that there is no fair substitute for exams, just a trade-off between different sets of injustices, as any fair-minded observer should acknowledge.  In another, it mars them, and deeply.

Wisdom after the event is journalistic stock in trade.  Few of the commentators who are now lashing Williamson and Gibb to the railway tracks were warning, during the last few months, that a slow train called Algorithm was chuffing down the line.  It is none the less true that the vehicle’s rumbling and grinding will have been picked by Ministers and officials months from the moment when exams were cancelled, or should have been.

Some events in the life of a Minister are unpredictable.  For example, Grant Shapps can’t have known last week that a real-life train would crash in Aberdeenshire, with fatalities.  But A-level and GCSE results are the main outward-facing events in the yearly cycle of the Education Department, comparable to the place that the Budget and pre-Budget Report hold for the Treasury (and the same goes for their equivalents in the devolved institutions).

As we write, Conservative MPs’ WhatsApp groups are buzzing with the question: what went wrong?  Why did the Department rush out its plan to take “valid” mocks into account only after the Scottish debacle?  How come Ofqal tore up advice that it had issued on the same day?  Why the pause over whether or not appeals would be free?  Could not the public have been softened up for the perceived advantage that the algorithm gave to private schools?

At some point soonish, answers to these questions, and others, will begin to emerge: it is too early, as events continue to develop, to find them now.  What matters most now is patching up the A-level wounds; heading off this week’s coming GCSEs from trouble, and restoring credibility to a department and a Government that must succeed, during the coming weeks, where it failed this summer – that’s to say, in getting schools to open.

With A-levels, the die is already cast.  The showboating and bandwagon-jumping of Keir Starmer and Angela Rayner is no more than that: manoeuvering for position.  The option of Doing a Scotland, and reverting to predicted grades, no longer exists – at least, not if the stitching-together of places which the universities have begun is not to be unstitched, with all the new injustices that such a move would threaten.

That leaves, very broadly, the options of either standing by last week’s results or by-passing them via the appeals system.  There is little doubt which one Ministers favour: they will be hoping that the appeals process will apply balm to the algorithm’s wounds.  There are at least three major problems here, even assuming that the system is not swamped by more appeals than the Education Department expects.

First, a successful appeal may well come too late to matter, at least as far as the pupil’s original offer is concerned.  Second, it isn’t at all clear whether the appeals bodies will play ball; Ofqal’s dynamiting of Ministers’ position on mocks suggest that they may not.  Finally, those for whom an appeal is not successful, and who are not going on to higher education, will have the algorithm’s verdict as the last word on their academic record, in many cases.

In any event, the Government should grease the palms of the universities, thus enabling them to take in the extra students that the appeals process will wave through.  With GCSEs, the choices range wider.  Ministers could simply let the teacher-assessed recommendations or previously predicted grades stand.  Or, as Ken Baker is suggesting, pull the results altogether (with students sitting exams during the autumn).

We end where we began.  There is no perfect option open to the Government – only a choice between imperfect options.  Yes, letting predicted grades prevail would risk the injustices of which Gibb wrote. And there would be knock-on funding consequences for some colleges, sixth forms and FEs if others take more than their planned number of pupils.

But grade inflation is less dangerous at GCSE – since many pupils go on to further and higher education and to further assessments and exams – than it is higher up the educational food chain.  Letting predicted grands stand is the most reliable way of body-swerving this week’s elephant trap, and allowing the Education Department to channel its energies into getting schools open this autumn.  Without which much of the economy will stay shut.