Problem 1680 · Medium

Concatenation of Consecutive Binary Numbers

Join the binary forms of the numbers one through n into one long binary number and return it modulo a large prime. The visual shows the running value shifting left as each new number is appended.

Open the interactive visualisation