hi all
can i know how to find greatest of two numbers?
the condition is we should not use any comparision operators..
thanks in advance

Modern programming education: where you learn totally useless stuff at the expense of useful stuff.

can i know how to find greatest of two numbers?
the condition is we should not use any comparision operators..

You can easily find the answer to this on google. I can't in good conscience enable stupid teachers by assisting with stupid homework. Sorry.

Edited 4 Years Ago by deceptikon: n/a

that's a great reply
Didnt expect this kinda reply
but its not just homework from our teachers..
but also the questions asked in the HR round of interview

anyhow thanks for the suggestion

Edited 4 Years Ago by sharathg.satya: n/a

but also the questions asked in the HR round of interview

What little respect I had for the business world has just died.

What little respect I had for the business world has just died.

its just trying to filter the one who can think more..

More like it's filtering out the better candidates because they won't consider an employer that cares more about trivia than real skills.

Comments
Agree :)

but also the questions asked in the HR round of interview

I agree it's used to weed out candidate that can program. The answer to give the HR guy is "of what use is finding the greatest of two numbers without using comparison operators? Do you recommend using convoluted programming practices in the code created here?"

This response shows you are thinking of the employer and you'd rather write straight forward code than obfuscated code.

Edited 4 Years Ago by WaltP: n/a

I agree it's used to weed out candidate that can program. The answer to give the HR guy is "of what use is finding the greatest of two numbers without using comparison operators? Do you recommend using convoluted programming practices in the code created here?"

This response shows you are thinking of the employer and you'd rather write straight forward code than obfuscated code.

thanks for the reply

This question has already been answered. Start a new discussion instead.