WINIT Software interview question

2 questions one is a general program,another program is a pattern