Replacing inArr with inSet

Could you check that it works on your local machine?