Rule reminder
The article in 'il cui / la cui / i cui / le cui' agrees with the NOUN THAT FOLLOWS 'cui', not with the antecedent. Ask: what gender and number is the noun after 'cui'?
Lo studente ___ zaino è sul banco non è arrivato.