I realised that it was too easy to miss that you have completed a level and then die by catching a wrong prime.
While commenting the code I found an opportunity to save three more characters. I’ve used two of those to change the background colour whenever you complete a level, so that it is now obvious when you have a new objective.