removed comments from q1, works on medium test case in under 5s