Tree recursion in practical use