# height(Poset) -- computes the height of a poset

## Synopsis

• Function: height
• Usage:
h = height P
• Inputs:
• P, an instance of the type Poset,
• Outputs:

## Description

The height of a poset is one less than the length of the longest chain.

The $n$ chain has height $n-1$.

 i1 : n = 5; i2 : height chain n o2 = 4