Re: [algogeeks] probability

2011-01-01 Thread RAHUL KUJUR
Suppose three gunmen are A, B, and C who have a probability of 100%, 50% and 33% respectively. The shooting will start from C, then B and at last A. Now there are several possibilities for C. If C shoots B, then A would shoot C with an accuracy of 100% or in other case if C shoots A, then B would

Re: [algogeeks] Re: probability

2011-01-01 Thread RAHUL KUJUR
@Dave: first of all By shooting in air I meant that C will not fire any one. That was my figure of speech:)) He will simply waste his shot. @Salil: its a duel. everyone will get chance to shoot in each round -- You received this message because you are subscribed to the Google Groups

Re: [algogeeks] Re: probability

2011-01-01 Thread RAHUL KUJUR
@snehal: will the shooting take place in increasing order of accuracy of hitting the target and is that at a time only one person can take a shot??? if yes then @Salil: my answer would be the same as above. what C will do is that it will first let A and B kill each other first. After C wastes his

Re: [algogeeks] spy in the city

2010-12-19 Thread RAHUL KUJUR
Is there any condition that the people in the city may or may not know each other??? -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@googlegroups.com. To unsubscribe from this group, send email to

Re: [algogeeks] Re: C aps ques

2010-12-14 Thread RAHUL KUJUR
for 2nd problem: statement inside the do-while is executed once. Now for the condition checking inside the while loop. The condition i++5 is evaluated which turns out to be true. So the rest of the part ++ch='F' is not evaluated and hence letter A is printed six times. Now when the condition i++5

Re: [algogeeks] Re: C aps ques

2010-12-14 Thread RAHUL KUJUR
correct me if I am wrong. -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.com. For more options,

Re: [algogeeks] Re: Smallest window of K[] in N[]. Best order solution

2010-10-07 Thread RAHUL KUJUR
@prodigy: how is it coming O(nlogk) can u explain??? -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@googlegroups.com. To unsubscribe from this group, send email to

Re: [algogeeks] Do This

2010-10-06 Thread RAHUL KUJUR
Take two pointers p and q. Initially p points to head. while(p!=given pointer) { p=p-link; q=p; }; Now you hv pointer at 3rd and 4th position. Now insertion is simpleHope this will work -- You received this message because you are subscribed to the Google Groups Algorithm Geeks

Re: [algogeeks] Do This

2010-10-06 Thread RAHUL KUJUR
@shobhan: Ya,I got it!! -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.com. For more options,