<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Max Jeffer</title>
    <description>The latest articles on DEV Community by Max Jeffer (@max_jeffer_c000763500fa88).</description>
    <link>https://dev.to/max_jeffer_c000763500fa88</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F1925448%2F838b9173-1f3c-45a1-8267-38c5a428e028.jpg</url>
      <title>DEV Community: Max Jeffer</title>
      <link>https://dev.to/max_jeffer_c000763500fa88</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/max_jeffer_c000763500fa88"/>
    <language>en</language>
    <item>
      <title>Tictactoe in a Terminal Built with Python</title>
      <dc:creator>Max Jeffer</dc:creator>
      <pubDate>Tue, 13 Aug 2024 23:26:45 +0000</pubDate>
      <link>https://dev.to/max_jeffer_c000763500fa88/tictactoe-in-a-terminal-built-with-python-442c</link>
      <guid>https://dev.to/max_jeffer_c000763500fa88/tictactoe-in-a-terminal-built-with-python-442c</guid>
      <description>&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F1lol82ihq5mjq41ofv5g.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F1lol82ihq5mjq41ofv5g.jpg" alt="Tictactoe" width="800" height="500"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Team&lt;/th&gt;
&lt;th&gt;GitHub&lt;/th&gt;
&lt;th&gt;Country&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Max Jeffer&lt;/td&gt;
&lt;td&gt;&lt;a href="https://github.com/M21x1" rel="noopener noreferrer"&gt;@M21x1&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;Peru&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Tictactoe or Noughts and Crosses is a two player, they take turns, game where the only rule to win is to draw the same sign vertically, horizontally or diagonally on a three by three grid.&lt;/p&gt;

&lt;p&gt;We will build the program using 5 modules:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;  The grid printer&lt;/li&gt;
&lt;li&gt;  The input getter&lt;/li&gt;
&lt;li&gt;  The switch player&lt;/li&gt;
&lt;li&gt;  The winner determiner&lt;/li&gt;
&lt;li&gt;  The game developer&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The above list can be daunting but no worries..I was too, hehe. &lt;/p&gt;

&lt;p&gt;First, the grid printer is a function that uses a dictionary to print out an initial frame where the players will be placing their signs.&lt;/p&gt;

&lt;p&gt;Second, the input getter is where the terminal will ask a player to input a sign, imposing some restriction to not cause an error in the game like the input must be a number between 1 - 3.&lt;/p&gt;

&lt;p&gt;Third, the switch player is the most simple function of them all, it just changes turns between players.&lt;/p&gt;

&lt;p&gt;Fourth, the winner determiner is like a filter to check horizontally, vertically and diagonally if one of the player got three consecutive signs.&lt;/p&gt;

&lt;p&gt;Finally, the game developer relates the four functions described and initializes the game.&lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
