Formats a number with an explicit sign prefix (+, -, or ± for zero).
Parameters
n: number
The number to format.
Optionalmin_len: number
Minimum UTF-16 length of the numeric part, excluding the sign.
Optionalfill_string: string
Padding string (default: ' ').
Returns string
The formatted string with sign prefix.
Remarks
Uses the number's string representation without rounding or truncating it to an
integer. Padding is applied before the numeric part but after the sign; an empty
padding string adds nothing. Both positive and negative zero use ±.
Formats a number with an explicit sign prefix (
+,-, or±for zero).