Freddie Mac Interview Question

Write a code in any language to calculate the square root of a number without the in-built function