AI and Sustainability: the Two Sides of the Coin