prototype description
high-level algorithm