← RoseCode

ROSECODE 490

A self referential sequence

Philippe_57721 · Programming ·

The sequence G={1,2,2,3,3,4,4,4,5,5,5,} is defined by:
Gn=number of occurences of n in the sequence.

G4=3the number 4 occurs 3 times in the sequence.

What is m=G123456789101112?

Find the smallest n such as Gn=123456654321

You are given 1684,128276792 for 123456,123321

Answer format: m,n

[My timing: 1.5 sec]