
Sponsored
Sponsored
Use these hints if you're stuck. Try solving on your own first.
Find the binary representations of <code>n</code> and <code>k</code>.
Any bit that is equal to 1 in <code>n</code> and equal to 0 in <code>k</code> needs to be changed.