partially solved p1