## Sequence Puzzle

The below is a number puzzle. It should be read left to right, top to bottom.
Question 1 What is the next two rows of numbers.
1 1
2 1
1 2 1 1
1 1 1 2 2 1

1. Very simple.
3 1 2 2 1 1

3 1 2 2 1 1
1 3 1 1 2 2 2 1

Count the number.The second row states that there are two one's in the 1st row.Follow the similar logic for all the rows.

3. nice puzzle man, love your blog

4. for every row count the same consecutive number and print the count first and then the number

line 1 : 1 1
line 2(2 times 1) : 2 1
line 3(1 time 2 and 1 times 1) : 1 2 1 1
line 4(1 times 1, 1 times 2 and 2 times 1) : 1 1 1 2 2 1
line 5(3 times 1 2 times 2 and 1 times 1): 3 1 2 2 1 1
Similarly:
line 5 : 1 3 1 1 2 2 2 1

5. @Harshit : can you explain the logic more clearly ??

6. 5th row is :2 2 1 1 1 1 1 2 1 1
6th row is : 1 1 2 1 1 2 2 1 1 1 1 1 1 2 2 1

1. Start off with 2 rows first

1 1
2 1

2. To get the 3rd row:
- Divide previous row(2nd row) into 2 equal parts and then switch places
1 2
- Add the the previous to previous row(1st row) to the end of it.
1 2 1 1
3. To get the 4th row:
- Divide the 3rd row into 2 equal parts and switch places
1112
- Add the 2nd row to the end
1 1 1 2 2 1
4. To get the fifth row:
- Divide the 4th row into 2 equal parts and switch places
221111
- Add the 3rd row to the end
2 2 1 1 1 1 1 2 1 1

5. To get the 6th row..... do the same thing
1 1 2 1 1 2 2 1 1 1 1 1 1 2 2 1

7. 212112
121111

8. 212112
121111