alt solution to p1 clj