Did you study well at school? — My friend asked me if I had studied well at school.
When can children leave school? — My friend asked me when children could leave school.
Have your perents visited London? — My friend asked me if my parents had visited London.