Cadence Design Systems interview question

Lc medium level and easy one