Window Open Function working

Works for puzzle 1 and puzzle 2