A game that lets players to experience software development is an excellent method to teach coding and programming concepts like loops and conditional statements. Games that allow this include Zachtronics’ Shenzhen I/O, which puts players in the shoes of disaffected engineers working for an ordinary chip manufacturer and must build computer chips by hand. They are given increasingly complex circuits to design. They begin with making lights blink in a certain pattern.
The game’s interface looks very similar to developer tools found in browsers and teaches scripting. Another great example is Screeps which incorporates JavaScript programming with massively multiplayer online gameplay to build self-sustaining colonies. Both games do a wonderful job of teaching fundamental concepts while also slowly introducing new ones.