solution to Q1 is added