practice common algorithms