UK inflation hits 40-year high of 9% as energy costs rocket