Click anywhere within the data to be subtotaled. Click the Data tab. Click the Subtotals button.
Select the appropriate check boxes to specify how the data is subtotaled. Click OK.
Check the result.