Description
Count written decimal places and fractional trailing zeros.
Numeric-looking text has both a value and a written form. Signs, decimal places, exponent markers and trailing zeros can carry display information that ordinary numeric conversion discards; formatting a token does not verify its meaning.
Count written decimal places and fractional trailing zeros.
When to use this tool
Use Decimal Trailing Zero Significance Tag when you need the specified literal representation or text-level numeric diagnostic.
How to use the tool and how it works
- Enter token. Use the units and conventions below.
- Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
- Read decimals, trailingZeros. Use the output convention below.
Require signed decimal text containing a fractional part. Count written decimal places and fractional trailing zeros.1
| Input field | Meaning and units | Accepted input |
|---|---|---|
| token | Token | Required. Text; maximum UTF-16 length 8192. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| decimals | Decimals | Required. Safe integer. |
| trailingZeros | Trailing Zeros | Required. Safe integer. |
{
"input": {
"token": "12.3400"
},
"output": {
"decimals": 4,
"trailingZeros": 2
}
} Limitations and assumptions
- Written zeros describe the token, not verified measurement precision; no numeric rounding, equality test, or significant-digit inference is performed.
- Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.
Alternative or Complementary methods
Use a locale-aware or destination-specific formatter when broader parsing and presentation rules are needed. Retain original text when lexical precision matters and validate numeric meaning separately.
References
Similar or alternative tools
- Trailing Zero Preservation Flag
Parse each signed ordinary decimal token and count only its fractional trailing zeros.
- Formatting: Decimal Uncertainty Last Place Label
Append parentheses and return numeric uncertaintyDigits times 10 to the negative fractional-place count.