vivekanand3435
BAN USER- 0of 0 votes
AnswersGiven the coordinates of N points in a plane. Assume the standard 2D quadrant system for representation of points.
- vivekanand3435 in India
Problem is - Find the centre and radius of a circle which passes through the maximum number of points. The centre must be one out of the given N points.| Report Duplicate | Flag | PURGE
Amazon Software Engineer / Developer Algorithm - 0of 0 votes
AnswersGiven the coordinates of N points in a plane. Assume the standard 2D quadrant system for representation of points.
- vivekanand3435 in India
Problem is - Find the centre and radius of a circle which passes through the maximum number of points. The centre must be one out of the given N points.| Report Duplicate | Flag | PURGE
Amazon Software Engineer / Developer Algorithm
Well I told that I will create a hashmap, with every cordinate and distance as key and count of eqidistance point as valus. then finally the key for the entry in Hash map with max count will be centre and distance for that hash map will be the radius of the circle. Then I was asked to code for the same.
- vivekanand3435 April 13, 2012Hi
1. first of all I was ask to take one online programming test which had 3 questions. out of those I solved 2 and 3rd one partially.
2. Then I had a telephonic interview in which I was asked to write a program to calculate the max depth of a binary tree followed by a long discussion on the time and space complexity of the same.
3. Then I was called to Hyderabad for in-person interview. There in first I was asked to write a program, which I dont remember.
4. Followed by next round by two interviewer and I was asked this question. He asked about algorithm followed by code for the same.
Then I was told that they will update on Monday. On Monday I got the bad news about end of my interview process with Amazon.
They put a lot of emphasis on writing a clean piece of code. So practice a lot before appearing for interview.
However It was a great experience. Hope to make it to final round next time.
you are right!!
- vivekanand3435 April 13, 2012