tcng currently only has one function: the formatted output function sprintf that returns a string, like the function with the same name in Perl.
The usage is like in C or Perl, and the following components are recognized in a conversion specification (see section B1.2 of [] for further details):
-
for left adjustment
0
for leading zeroes
*
f" or \verb"s
: the
precision, or *
d", \verb"u", \verb"o", \verb"x
,
X", \verb"f", \verb"c", \verb"s", and \verb"%
When using the conversion character %
, the whole specification
must be %%
.
Example:
$tag = "item"+sprintf("%04d",$number);