first solution to P0406