The economy grew by 0.1% in August, defying analysts' expectations of a slight contraction.