# Number sequence puzzle stuck on

Stuck on this number sequence puzzle for a while now, today was talking about IQ tests with somebody so thought I'd ask here.

1, 2, 33, ?, 555, 23, ?, 222

The source is INRC 2018 Q3 (btw if anyone wants to I still have 14 questions there I still couldn't figure out, including this one, happy to work on it together).

$$1,2,33,22,555,23,7777,222$$.
Factor the number if it is not prime, else if it is the $$n^{th}$$ prime, write it $$n$$ times.