Axiomatic and Brain-sized Coding in Swift for Creating Systems of Any Scale
<p>In math and logic, an axiom is a statement that can be considered true without further proving. 2 + 2 = 4 is an axiom. As is the fact that every natural number n has a successor n+1.</p>
<p>“Axiomatic Codes” feature such statements as well. Any user interaction or any other change goes through one or more of these statements. Here is one way to achieve this:</p>
<p>This is the game “Snake”. Its main data structure defines in the <code>Change</code> enum any interaction that is possible: move right, left, or forward. and grow.</p>
<p>The <code>Facing</code> enum defines in what direction it might be facing at any given moment. North, South, East, and West</p>
<p><a href="https://betterprogramming.pub/axiomatic-and-brain-sized-coding-in-swift-for-creating-systems-of-any-scale-ec352e7d87a9"><strong>Learn More</strong></a></p>