Comments added, debugging lines removed, stepSize variable introduced