The link [Wolfram Alpha](https://www.wolframalpha.com/input/?i=nextprime((10%5E32)%5E2) looks fine in preview, but is broken after submitting the question or answer:
A workaround is to use the [...][1]
syntax.
I don't think this is a duplicate of allow n-dashes in link URLs. This issue seems to be related to the round brackets.
[Wolfram Alpha](https://www.wolframalpha.com/input/?i=nextprime\(\(10%5E32\)%5E2)
(
and)
are allowed in URL, so "URL encoding" will leave them untouched, maybe you meant percent encoding, but I don't see how this would be "far better", since the problem here is not with the URL resolution, but with the markup syntax, escaping seems more appropriate.