second variant. Bottom up approach.