These are amateur-level mistakes where someone has been put in charge of a door and not thought it through. Thankfully, nowadays an expert will have planned the entrances and exits to a building, but it wasn’t always that way. Many lives have been saved or lost as a consequence of the simple geometry of which way a door should open.