I think this works and the complexity is O(sqrt(n))
#includecmath
#includecstdio
#includeiostream
#includecstring
#includecstdlib
using namespace std;
# define INFY 17
int main()
{
int n, i, j;
int val, minDiv, minDis;
while(1)
{
cin n;
minDis =
thank you for telling the unworkability of my algo.
i did not see the puzzle completely. my algo works only for BST.
Thank you,
Sid.
phone:+91-8971070727,
+91-9916809982
On Wed, Mar 21, 2012 at 8:49 PM, Lucifer sourabhd2...@gmail.com wrote:
@All
[ Let the tree to be searched in be 'T' and
+1 @ anurag's solution.agree with O(sqrt(n)) complexity.
--
Amol Sharma
Third Year Student
Computer Science and Engineering
MNNIT Allahabad
http://gplus.to/amolsharma99
http://twitter.com/amolsharma99http://in.linkedin.com/pub/amol-sharma/21/79b/507http://www.simplyamol.blogspot.com/
Hi
Do any one know how to configure MySQL Connector ; so as to connect to
MySql using C.If any one have any idea ; please share.
--
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.
My friend, all you have to do is read the manual.
http://dev.mysql.com/doc/refman/5.6/en/c.html
On Mar 22, 1:14 pm, Gobind Kumar Hembram gobind@gmail.com wrote:
Hi
Do any one know how to configure MySQL Connector ; so as to connect to
MySql using C.If any one have any idea ; please
I'll point out that if you are building a system where this problem
actually occurs (as in generating DAGs in a compiler expression
optimizer), you can nearly always engineer the problem down to O(log(|
T|)) if T is balanced and O(|T|) in the worst case.
Trees need parent pointers, and also a map
@atul:
Anurag's code has illustrated the idea of O(sqrt(E)) solution.
One more thing to optimize is that we can safely break after finding the
first factor of E which is less than sqrt(E).
So the code could be changed to:
but the worst case still remains O(sqrt(E))
--
Amol Sharma
Third Year Student
Computer Science and Engineering
MNNIT Allahabad
http://gplus.to/amolsharma99
http://twitter.com/amolsharma99http://in.linkedin.com/pub/amol-sharma/21/79b/507http://www.simplyamol.blogspot.com/
On Fri, Mar 23,
*Hello,
I am very much interested in android development and also i have made few
apps with eclipse and also with app inventor.
I need to know what else i can do to contribute in app inventor to get
selected in GSOC besides from just filling the application.
*Thanking you
*With regards-
Raghav
Hii to all
how to make a call of class's method(function) from client side to
server in java?
please replyit's urgent
--
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
using ajax..hit google for ajax...
On Fri, Mar 23, 2012 at 10:07 AM, Aman Kumar amanas...@gmail.com wrote:
Hii to all
how to make a call of class's method(function) from client side to
server in java?
please replyit's urgent
--
You received this message because you are subscribed to
there would be better way of doing so, but one of the simplest way to do so
is by serializing the object whose method you need to call, inside object
you need to have one more attribute say int code.
each code are distinct for each methods in that class.Now when server
receive this object and
if u have a web application then ajax is good else for desktop type
applications u can also look into remote procedure calls in java.
/Rishabbh
On Fri, Mar 23, 2012 at 10:24 AM, atul anand atul.87fri...@gmail.comwrote:
there would be better way of doing so, but one of the simplest way to do
13 matches
Mail list logo