Structural factors affecting acid strength and base strength