To compute the standard deviation, we first need the array of distances from the mean. So, we consider the difference between each element of the dataset and the mean:
which is
Then, we need to square this array:
Then, we consider the mean of this new array, so we sum its components and divide by the number of elements:
This is the variance, i.e. the standard deviation squared. So, we only need to take the square root of the variance to get the standard deviation: