# calculating the hydrostatic pressure in a non-cuboid shaped container [duplicate]

I want to calculate the hydrostatic pressure on the base at the following containers,but as you can see, the water are affecting the sides,especially in container 1, so does the formula $p$ $=$ $\rho$gh still applies in the these cases ?