@Ravindra
may be the interviewer wants from u that instead of blindly checking for
every number. first check that particular number can be written as the sum
of two squares or not if yes than only search for that number. So the order
will be decrease from O(n^2) to O(n * (number of side which is largest one
for any triplet)) and in practical it will be much less compare to O(n^2);

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.

Reply via email to