Boolean function has other uses
XML
<Animal>
<legs>4</legs>
<eyes>2</eyes>
<horns>2</horns>
<tail>1</tail>
</Animal>
XPATH
boolean(/Animal/tusks)
OUTPUT
false
XPATH
<Animal>
<legs>4</legs>
<eyes>2</eyes>
<horns>2</horns>
<tail>1</tail>
</Animal>
XPATH
boolean(/Animal/horns)
OUTPUT
true
XML
<House>
<LivingRoom>
<plant name="rose"/>
</LivingRoom>
<TerraceGarden>
<plant name="passion fruit"/>
<plant name="lily"/>
<plant name="golden duranta"/>
</TerraceGarden>
</House>
XPATH
boolean(/House//plant)
OUTPUT
true