But storing an index for a file of length 2^n takes only n bits, so you need that run of 0’s to be of length n+1 to win