# [MathGolf](https://github.com/maxbergmark/mathgolf/blob/master/create_explanation.py), 10 [bytes](https://github.com/maxbergmark/mathgolf/blob/master/code_page.py) ∞╒g¶áÅ-±├Þ [Try it online.](https://tio.run/##ATEAzv9tYXRoZ29sZv//4oie4pWSZ8K2w6HDhS3CseKUnMOe//84MAoxMDAKNQo5CjUzMgox) **Explanation:** <!-- language-all: lang-python --> ∞ # Double the (implicit) input-integer ╒ # Create a list in the range [1, 2*n] g¶ # Filter so only the prime numbers remain áÅ # Sort this list using the next two character: -± # The absolute difference with the (implicit) input-integer ├ # Push the first item of the list # (unfortunately without popping the list itself, so:) Þ # Discard everything from the stack except for the top # (which is output implicitly as result)