This is a Simon game implementation. I coded it for practice within the FreeCodeCamp curriculum.
Simon is an electronic game of memory skill invented by Ralph H. Baer and Howard J. Morrison,[1] with software programming by Lenny Cope, The device creates a series of tones and lights and requires a user to repeat the series. If the user succeeds the series becomes progressively longer and more complex.
You can see how it works here.