Gates was born in Seattle, Washington on October 28, 1955. He is the son of William H. Gates, Sr.[b] and Mary Maxwell Gates. Gates' ancestral origin includes English, German, and Irish, Scots-Irish.[18][19] His father was a prominent lawyer, and his mother served on the board of directors for First Interstate BancSystem and the United Way. Gates's maternal grandfather was JW Maxwell, a national bank president. Gates has one elder sister, Kristi (Kristianne), and one younger sister, Libby. He was the fourth of his name in his family, but was known as William Gates III or "Trey" because his father had the "II" suffix.[20] Early on in his life, Gates's parents had a law career in mind for him.[21] When Gates was young, his family regularly attended a Protestant Congregational church.[22][23][24] The family encouraged competition; one visitor reported that "it didn't matter whether it was hearts or pickleball or swimming to the dock ... there was always a reward for winning and there was always a penalty for losing".[25]
At 13, he enrolled in the Lakeside School, a private preparatory school.[26] When he was in the eighth grade, the Mothers Club at the school used proceeds from Lakeside School's rummage sale to buy a Teletype Model 33 ASR terminal and a block of computer time on a General Electric (GE) computer for the school's students.[27] Gates took an interest in programming the GE system in BASIC, and was excused from math classes to pursue his interest. He wrote his first computer program on this machine: an implementation of tic-tac-toe that allowed users to play games against the computer. Gates was fascinated by the machine and how it would always execute software code perfectly. When he reflected back on that moment, he said, "There was just something neat about the machine."[28] After the Mothers Club donation was exhausted, he and other students sought time on systems including DEC PDP minicomputers. One of these systems was a PDP-10 belonging to Computer Center Corporation (CCC), which banned four Lakeside students – Gates, Paul Allen, Ric Weiland, and Kent Evans – for the summer after it caught them exploiting bugs in the operating system to obtain free computer time.[29][30]