# \writelength¶

Command in package length.

## Synopsis¶

```
\writelength[unit][format]{length}
```

## Description¶

Prints out length. The output is composed of value and length, e.g., "12em".

By the optional argument unit a length unit other than the one of length

can be specified for the output. format, if set, must be of the form "m.n"; where m is the total

number of digits and n the number of digits after the decimal point.

## Example 1¶

```
\newlength{\mylength}[10mm]
\writelength{\mylength}
```

Result, as rendered by your browser

10.000000mm

## Example 2¶

```
\newlength{\mylength}[10mm]
\writelength[px][10.2]{\mylength}
```

Result, as rendered by your browser

28.35px

This page is generated automatically and each change here will be replaced on a next update.