2021年4月9日星期五

Reading Polynomials - Alter Spacing in String

Is there a regex that converts uneven spacing into even spacing in strings (for polynomials)?

Like "x^2 + x -3 +2x^-4" into "x^2 + x - 3 + 2x^-4" (where there is single space between each of the terms).

https://stackoverflow.com/questions/67030066/reading-polynomials-alter-spacing-in-string April 10, 2021 at 09:44AM

没有评论:

发表评论