A number has odd divisor or not

Revision en1, by Selim_Al_Sumon, 2023-01-14 20:52:34

A number never have a odd divisor which can be represent as the power of two. A famous way to find out the number can be represent as the power of two or not is:]

n & (n — 1) by this operation we will get a number which is an even number also the number can be represent by the power of two.So if by doing this operation we get any number which is represent by the power of two.That means 'n' has no odd divisor.

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en2 English Selim_Al_Sumon 2023-01-14 20:53:45 24 Tiny change: 'd divisor.' -> 'd divisor.watch the problem\n1475A'
en1 English Selim_Al_Sumon 2023-01-14 20:52:34 454 Initial revision (published)