An encoding which provides a bijection between the labeled trees on nodes and strings of integers chosen from an alphabet of the numbers 1 to . A labeled tree can be converted to a Prüfer code using LabeledTreeToCode[g] in the Wolfram Language package Combinatorica` , and a code can be converted to a labeled tree using CodeToLabeledTree[code]. Prüfer's bijection is based on the fact that every tre
![Prüfer Code -- from Wolfram MathWorld](https://cdn-ak-scissors.b.st-hatena.com/image/square/0e9d199124b73759f3b9521de077899dacaf484d/height=288;version=1;width=512/https%3A%2F%2Fmathworld.wolfram.com%2Fimages%2Fsocialmedia%2Fshare.png)