Goldman Sachs interview question

how to find square root of integer

Interview Answers

Anonymous

11 Nov 2015

double answer = java.Math.sqrt( ); You could use some other method. but that would be doing it wrong.

1

Anonymous

30 Sept 2013

Newton's Method: http://en.wikipedia.org/wiki/Newton's_method#Square_root_of_a_number

Anonymous

19 May 2010

binary search

4