Sum of greatest odd divisor of numbers

Revision en3, by From_ITK18_With_Love, 2021-09-20 11:49:11

Today, I get a problem.

Sum of greatest odd divisor of numbers in range $[a, b]$ with $a, b <= 10^9$

I found solution here : https://www.geeksforgeeks.org/sum-of-greatest-odd-divisor-of-numbers-in-given-range/

But I think the solution is not clear for the even number case.

Can find a better solution or more detailed explanation ?

Thanks you.

#### History

Revisions

Rev. Lang. By When Δ Comment
en3 From_ITK18_With_Love 2021-09-20 11:49:11 0 (published)
en2 From_ITK18_With_Love 2021-09-20 11:39:44 2 Tiny change: ' my englist was bad.\' -> ' my english was bad.\' (saved to drafts)
en1 From_ITK18_With_Love 2021-09-20 09:08:41 430 Initial revision (published)