Comment on Implementing Tic Tac Toe with 170mb of HTML - no JS or CSS

<- View Parent
Treczoks@kbin.social ⁨11⁩ ⁨months⁩ ago

Indeed. One could have done the whole thing with a simple, static HTML page.

On top an empty board with 9 clickable fields. Each of them links to a new, pre-rendered board on the same page, with the move of the player and the perfect reply of the computer already in place, and 7 clickable fields. Which link to other, pre-rendered boards with 5 clickable fields remaining, then with three. The last one only has one field open, so this could be pre-filled as a player move.

All in all this would result in 9x7x5x3=945 pre-rendered boards max on that page. And, of course, two links to "You won" and "You Lost". I'm no HTML junkie, so I have no idea how many bytes one would need to produce such a board, but I'm sure this all could easily done way below 170MB.

source
Sort:hotnewtop