Bill Gates’s first computer program was a tic-tac-toe game.
Gates wrote the program as a student after gaining access to a computer at Lakeside School in Seattle. The school’s computer time was initially provided through a local company’s arrangement, and Gates quickly became interested in experimenting with code rather than merely using software made by others.
A tic-tac-toe program was a natural early project because the game has simple rules, a small playing grid, and a clear way to test whether a computer can respond to a human move. This early exercise did not itself create Microsoft, but it illustrates how Gates’s programming interests developed before his partnership with Paul Allen.
The story is sometimes confused with Gates’s later work on BASIC for the Altair 8800. Tic-tac-toe was an early personal programming project; the Altair BASIC interpreter was a professional software product developed years later, in 1975.