Binary Pattern (1)

In binary puzzles , a grid must be filled with ones and zeroes. Each column and row must be a sequence following these rules:

  • The numbers of zeroes and ones are equal.
  • There may be no subsequence of three or more of the same number (zero or one).

For instance, 110010 110010 is a valid sequence; 100011 100011 is invalid because there are three zeroes in a row; 110101 110101 is invalid because there are more ones than zeroes.

How many valid sequences of length six are possible?


Want a greater challenge? Try this one .


The answer is 14.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

1 solution

The number of ways to place three ones in six positions is ( 6 3 ) = 20. \left(\begin{array}{c} 6 \\ 3 \end{array}\right) = 20. However, we must rule out patterns with three successive ones or zeroes. These are 000111 ; 111000 ; 011100 ; 100011 ; 001110 ; 110001. 000111;\ \ \ 111000; \\ 011100;\ \ \ 100011; \\ 001110;\ \ \ 110001. Therefore there are 20 6 = 14 20 - 6 = \boxed{14} valid sequences.

@Arjen Vreugdenhil But , I did it with hit and trial. Will you please explain it or is there any wiki for this , sir? Thanks!

Toshit Jain - 4 years, 3 months ago

Log in to reply

This is an application of combinations . Trial and error works well here, but becomes cumbersome for larger patterns, as in this problem .

Arjen Vreugdenhil - 4 years, 3 months ago

@Arjen Vreugdenhil Thanks , man!

Toshit Jain - 4 years, 3 months ago

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...