← Complete problem index

PROJECT EULER · #0760

Sum over Bitwise Operators

Statement only · SolvedOriginal problem ↗

Define g(m,n)=(mn)+(mn)+(mn) where ,, are the bitwise XOR, OR and AND operator respectively.

Also set G(N)=n=0Nk=0ng(k,nk)

For example, G(10)=754 and G(102)=583766.

Find G(1018). Give your answer modulo 1000000007.

Write-up coming later

The complete problem is available here. An approach, code, and answer will be added later.