ValueLabs Interview Question

How to handle frames & windows