The corporation is run by people and people favor short term results when they expect to be in their position for a short period.
Just as it's far less common for the regular working (wo)man to stay at the same company for decades, it's less common for CEOs to do so as well.[0]
If a CEO/president expects (through loyalty/control of the board, or otherwise) to be at the company for a long time, they will naturally make long(er) term decisions.
[0] https://en.wikipedia.org/wiki/List_of_Hewlett-Packard_execut...