Hint: Try to use the formula 180*(n-2) / n to find the measure of one angle of the octagon. Then, go from there.
It's better to draw the diagram first!
Geometry questions are always a nightmare to write answers to, but I'll give it my best shot. If we connect CH, we get a right triangle. The interior angle of a regular octagon is 135 degrees (make sure you see why!). Therefore, with CH being perpendicular to GH, we know that angle AHC= 45 degrees. Therefore, angle P is I believe 45 degrees.