Description

The Look and Say sequence is an interesting sequence of numbers where each term is given by describing the makeup of the previous term.

The 1st term is given as 1. The 2nd term is 11 (‘one one’) because the first term (1) consisted of a single 1. The 3rd term is then 21 (‘two one’) because the second term consisted of two 1s. The first 6 terms are:

1

11

21

1211

111221

312211

Formal Inputs & Outputs

Input

On console input you should enter a number N

Output

The Nth Look and Say number.

Bonus

Allow any ‘seed’ number, not just 1. Can you find any interesting cases?

Original exercise and other solutions:

http://www.reddit.com/r/dailyprogrammer/comments/2ggy30/9152014_challenge180_easy_looknsay/

## Comments