@biku look at the conditions
where x is equal to b
when a x b
suppose
1 5 5 , it should give FALSE ...
--
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
Yours can be used at the situation when
a x = b , Good one .,
--
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
i have attached a file consisting first by comparison and second by XORING
biku,.,. u shuld have a look at that..
--
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
srry for my wrong typo..
it should be
*
unsinged( x - a ) (unsigned)b - a*
works only for positive a and b a = b
--
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
how about ...if( (a-x)^(b-x) 0)
On Sat, Oct 27, 2012 at 9:21 PM, Dave dave_and_da...@juno.com wrote:
@Atul: Try x = 0, a = 1, b = 2, for which (x a x b) is false, but
(x - a b - x) is true.
Dave
On Saturday, October 27, 2012 5:43:17 AM UTC-5, ATul SIngh wrote:
Thnks but i figured
we can use masking of most significant bit of the xor of (a-x) and ( b-x)
to check if axb
if [ ((a-x)^(b-x)) 0x8000 ]
then it's in range
else not in range
On Sat, Oct 27, 2012 at 11:17 PM, Vikram Pradhan vpradha...@gmail.comwrote:
how about ...if( (a-x)^(b-x) 0)
biku u also dere in this group... coool bro :)
--
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
@Atul: Try x = 0, a = 1, b = 2, for which (x a x b) is false, but (x
- a b - x) is true.
Dave
On Saturday, October 27, 2012 5:43:17 AM UTC-5, ATul SIngh wrote:
Thnks but i figured it out
as
( x = a x b )
or
( x = a x = b )
could be written as
x -a b - xfor first case