Newton's method to find square root and scala learning project.