to_string for p1, and example bugfix