diff --git a/.i18n/en/Game.pot b/.i18n/en/Game.pot index b5466879..58d74d68 100644 --- a/.i18n/en/Game.pot +++ b/.i18n/en/Game.pot @@ -151,7 +151,7 @@ msgid "Nice!\n" "The next step in the development of order theory is to develop\n" "the theory of the interplay between §0 and multiplication.\n" "If you've already done Multiplication World, you're now ready for\n" -"Advanced Multiplication World. Click on \"Leave World\" to access it." +"Advanced Multiplication World. Click on \"Home\" to access it." msgstr "" #. §0: `a + b + c` @@ -206,7 +206,7 @@ msgid "Here's my proof:\n" "World, a more computer-sciency world, we will develop machinery which makes\n" "questions like this much easier, and goals like §1 feasible.\n" "Alternatively you can do more mathematics in Advanced Addition World, where we prove\n" -"the lemmas needed to get a working theory of inequalities. Click \"Leave World\" and\n" +"the lemmas needed to get a working theory of inequalities. Click \"Home\" and\n" "decide your route." msgstr "" @@ -387,7 +387,7 @@ msgstr "" #. §1: `b` #. §2: `d` #: Game.Levels.Algorithm.L02add_algo1 -msgid "Finally use a targetted §0 to switch §1 and §2" +msgid "Finally use a targeted §0 to switch §1 and §2" msgstr "" #. §0: `repeat t` @@ -1017,7 +1017,7 @@ msgid "§0, with notation §1, is\n" "* §3\n" "\n" "Other theorems about naturals, such as §4, are proved\n" -"by induction using these two basic theorems.\"" +"by induction using these two basic theorems." msgstr "" #. §0: $x+1=4$ @@ -1744,7 +1744,7 @@ msgid "*Game version: 4.3*\n" "## Resources\n" "\n" "* The [Lean Zulip chat](https://leanprover.zulipchat.com/) forum\n" -"* [Original Lean3 version](https://www.ma.imperial.ac.uk/~buzzard/xena/natural_number_game/) (no longer maintained)\n" +"* [Original Lean3 version](https://github.com/ImperialCollegeLondon/natural_number_game/) (no longer maintained)\n" "\n" "## Problems?\n" "\n" @@ -1800,7 +1800,7 @@ msgid "Here is an example proof of 2+2=4 showing off various techniques.\n" "move back into \"Typewriter mode\".\n" "\n" "You have finished tutorial world!\n" -"Click \"Leave World\" to go back to the\n" +"Click \"Home\" to go back to the\n" "overworld, and select Addition World, where you will learn\n" "about the §3 tactic." msgstr "" @@ -1970,7 +1970,7 @@ msgid "§0 is a proof that §1. But if your goal\n" "You don't need induction. §7 moves brackets around,\n" "and §8 moves variables around.\n" "\n" -"Remember that you can do more targetted rewrites by\n" +"Remember that you can do more targeted rewrites by\n" "adding explicit variables as inputs to theorems. For example §9\n" "will only do rewrites of the form §10, and §11\n" "will only do rewrites of the form §12." @@ -2147,7 +2147,7 @@ msgid "## Summary\n" "If you can't remember the name of the proof of an equality, look it up in\n" "the list of lemmas on the right.\n" "\n" -"## Targetted usage\n" +"## Targeted usage\n" "\n" "If your goal is §67 and you want to rewrite §68\n" "to §69, then §70 will not work because Lean finds another\n" @@ -2636,7 +2636,7 @@ msgid "How about this for a proof:\n" "§0\n" "\n" "That's the end of Advanced Addition World! You'll need these theorems\n" -"for the next world, §1 World. Click on \"Leave World\" to access it." +"for the next world, §1 World. Click on \"Home\" to access it." msgstr "" #. §0: `n` @@ -4241,7 +4241,7 @@ msgid "You've now seen all the tactics you need to beat the final boss of the ga "World. These tactics let you prove more facts about addition, such as\n" "how to deduce §0 from §1.\n" "\n" -"Click \"Leave World\" and make your choice." +"Click \"Home\" and make your choice." msgstr "" #: Game.Levels.LessOrEqual.L05le_zero diff --git a/.i18n/fr/Game.json b/.i18n/fr/Game.json index 82c7b3fa..c56421f7 100644 --- a/.i18n/fr/Game.json +++ b/.i18n/fr/Game.json @@ -75,12 +75,12 @@ "`zero_ne_succ n` est la preuve que `0 ≠ succ n`.\n\nDans Lean, `a ≠ b` est *défini comme signifiant* `a = b → False`. Par conséquent\n`zero_ne_succ n` est en réalité une preuve de `0 = succ n → False`.\nIci `False` est un énoncé faux générique. Cela signifie que\nvous pouvez `apply zero_ne_succ at h` si `h` est une preuve de `0 = succ n`.", "`zero_ne_one` is a proof of `0 ≠ 1`.": "`zero_ne_one` est une preuve de `0 ≠ 1`.", - "`zero_mul x` is the proof that `0 * x = 0`.\n\nNote: `zero_mul` is a `simp` lemma.": - "`zero_mul x` est la preuve que `0 * x = 0`.\n\nNote : `zero_mul` est un lemme `simp`.", + "`zero_mul m` is the proof that `0 * m = 0`.\n\nNote: `zero_mul` is a `simp` lemma.": + "`zero_mul m` est la preuve que `0 * m = 0`.\n\nNote : `zero_mul` est un lemme `simp`.", "`zero_le x` is a proof that `0 ≤ x`.": "`zero_le x` est une preuve que `0 ≤ x`.", - "`zero_add x` is the proof of `0 + x = x`.\n\n`zero_add` is a `simp` lemma, because replacing `0 + x` by `x`\nis almost always what you want to do if you're simplifying an expression.": - "`zero_add x` est la preuve que `0 + x = x`.\n\n`zero_add` est un lemme `simp`, car remplacer `0 + x` par `x`\nest presque toujours ce que vous voulez faire si vous simplifiez une expression.", + "`zero_add n` is the proof of `0 + n = n`.\n\n`zero_add` is a `simp` lemma, because replacing `0 + n` by `n`\nis almost always what you want to do if you're simplifying an expression.": + "`zero_add n` est la preuve que `0 + n = n`.\n\n`zero_add` est un lemme `simp`, car remplacer `0 + n` par `n`\nest presque toujours ce que vous voulez faire si vous simplifiez une expression.", "`xyzzy` is an ancient magic spell, believed to be the origin of the\nmodern word `sorry`. The game won't complain - or notice - if you\nprove anything with `xyzzy`.": "`xyzzy` est un ancien sortilège magique, considéré comme l'origine du\nmot moderne `sorry`. Le jeu ne se plaindra pas - ou ne remarquera pas - si vous\nprouvez quoi que ce soit avec `xyzzy`.", "`two_mul m` is the proof that `2 * m = m + m`.": @@ -129,7 +129,7 @@ "`one_mul m` est la preuve que `1 * m = m`.", "`one_le_of_ne_zero a` is a proof that `a ≠ 0 → 1 ≤ a`.": "`one_le_of_ne_zero a` est une preuve que `a ≠ 0 → 1 ≤ a`.", - "`one_eq_succ_zero` is a proof of `1 = succ 0`.\"": + "`one_eq_succ_zero` is a proof of `1 = succ 0`.": "`one_eq_succ_zero` est une preuve que `1 = succ 0`.", "`nth_rewrite 2 [two_eq_succ_one]` is I think quicker than `rw [two_eq_succ_one]`.": "`nth_rewrite 2 [two_eq_succ_one]` est je pense plus rapide que `rw [two_eq_succ_one]`.", @@ -218,9 +218,9 @@ "`add_left_cancel a b n` est le théorème que $n+a=n+b\\implies a=b$.\nVous pouvez le prouver par induction sur `n` ou le déduire de `add_right_cancel`.", "`add_left_cancel a b n` is the theorem that $n+a=n+b \\implies a=b.$": "`add_left_cancel a b n` est le théorème que $n+a=n+b \\implies a=b.$", - "`add_comm x y` is a proof of `x + y = y + x`.": - "`add_comm x y` est une preuve de `x + y = y + x`.", - "`add_comm b c` is a proof that `b + c = c + b`. But if your goal\nis `a + b + c = a + c + b` then `rw [add_comm b c]` will not\nwork! Because the goal means `(a + b) + c = (a + c) + b` so there\nis no `b + c` term *directly* in the goal.\n\nUse associativity and commutativity to prove `add_right_comm`.\nYou don't need induction. `add_assoc` moves brackets around,\nand `add_comm` moves variables around.\n\nRemember that you can do more targetted rewrites by\nadding explicit variables as inputs to theorems. For example `rw [add_comm b]`\nwill only do rewrites of the form `b + ? = ? + b`, and `rw [add_comm b c]`\nwill only do rewrites of the form `b + c = c + b`.": + "`add_comm a b` is a proof of `a + b = b + a`.": + "`add_comm a b` est une preuve de `a + b = b + a`.", + "`add_comm b c` is a proof that `b + c = c + b`. But if your goal\nis `a + b + c = a + c + b` then `rw [add_comm b c]` will not\nwork! Because the goal means `(a + b) + c = (a + c) + b` so there\nis no `b + c` term *directly* in the goal.\n\nUse associativity and commutativity to prove `add_right_comm`.\nYou don't need induction. `add_assoc` moves brackets around,\nand `add_comm` moves variables around.\n\nRemember that you can do more targeted rewrites by\nadding explicit variables as inputs to theorems. For example `rw [add_comm b]`\nwill only do rewrites of the form `b + ? = ? + b`, and `rw [add_comm b c]`\nwill only do rewrites of the form `b + c = c + b`.": "`add_comm b c` est une preuve que `b + c = c + b`. Mais si votre but\nest `a + b + c = a + c + b` alors `rw [add_comm b c]` ne\nfonctionnera pas ! Parce que le but signifie `(a + b) + c = (a + c) + b` donc il n'y a\npas de terme `b + c` *directement* dans le but.\n\nUtilisez l'associativité et la commutativité pour prouver `add_right_comm`.\nVous n'avez pas besoin d'induction. `add_assoc` déplace les parenthèses,\net `add_comm` échange les variables.\n\nRappelez-vous que vous pouvez faire des réécritures plus ciblées en\najoutant des variables explicites comme entrées aux théorèmes. Par exemple `rw [add_comm b]`\nne fera que des réécritures de la forme `b + ? = ? + b`, et `rw [add_comm b c]`\nne fera que des réécritures de la forme `b + c = c + b`.", "`add_assoc a b c` is a proof\nthat `(a + b) + c = a + (b + c)`. Note that in Lean `(a + b) + c` prints\nas `a + b + c`, because the notation for addition is defined to be left\nassociative.": "`add_assoc a b c` est une preuve\nque `(a + b) + c = a + (b + c)`. Notez que dans Lean `(a + b) + c` s'affiche\ncomme `a + b + c`, car la notation pour l'addition est définie comme étant\nassociative à gauche.", @@ -231,17 +231,17 @@ "`a ≠ b` is *notation* for `(a = b) → False`.\n\nThe reason this is mathematically\nvalid is that if `P` is a true-false statement then `P → False`\nis the logical opposite of `P`. Indeed `True → False` is false,\nand `False → False` is true!\n\nThe upshot of this is that you can treat `a ≠ b` in exactly\nthe same way as you treat any implication `P → Q`. For example,\nif your *goal* is of the form `a ≠ b` then you can make progress\nwith `intro h`, and if you have a hypothesis `h` of the\nform `a ≠ b` then you can `apply h at h1` if `h1` is a proof\nof `a = b`.": "`a ≠ b` est une *notation* pour `(a = b) → False`.\n\nLa raison pour laquelle c'est mathématiquement\nvalide est que si `P` est un énoncé vrai-faux alors `P → False`\nest l'opposé logique de `P`. En effet `True → False` est faux,\net `False → False` est vrai !\n\nLa conséquence est que vous pouvez traiter `a ≠ b` exactement\nde la même manière que toute implication `P → Q`. Par exemple,\nsi votre *but* est de la forme `a ≠ b` alors vous pouvez avancer\navec `intro h`, et si vous avez une hypothèse `h` de la\nforme `a ≠ b` alors vous pouvez utiliser `apply h at h1` si `h1` est une preuve\nde `a = b`.", "`Pow a b`, with notation `a ^ b`, is the usual\n exponentiation of natural numbers. Internally it is\n defined via two axioms:\n\n * `pow_zero a : a ^ 0 = 1`\n\n * `pow_succ a b : a ^ succ b = a ^ b * a`\n\nNote in particular that `0 ^ 0 = 1`.": - "`Pow a b`, avec la notation `a ^ b`, est l'exponentiation\n habituelle des nombres naturels, c'est à dire `a` puissance `b. En interne, elle est\n définie par deux axiomes :\n\n * `pow_zero a : a ^ 0 = 1`\n\n * `pow_succ a b : a ^ succ b = a ^ b * a`\n\nNotez en particulier que `0 ^ 0 = 1`.", + "`Pow a b`, avec la notation `a ^ b`, est l'exponentiation\n habituelle des nombres naturels, c'est à dire `a` puissance `b`. En interne, elle est\n définie par deux axiomes :\n\n * `pow_zero a : a ^ 0 = 1`\n\n * `pow_succ a b : a ^ succ b = a ^ b * a`\n\nNotez en particulier que `0 ^ 0 = 1`.", "`Mul a b`, with notation `a * b`, is the usual\n product of natural numbers. Internally it is\n via two axioms:\n\n * `mul_zero a : a * 0 = 0`\n\n * `mul_succ a b : a * succ b = a * b + a`\n\nOther theorems about naturals, such as `zero_mul`,\nare proved by induction from these two basic theorems.": "`Mul a b`, avec la notation `a * b`, est le produit\n habituel des nombres naturels. En interne, il est\n défini par deux axiomes :\n\n * `mul_zero a : a * 0 = 0`\n\n * `mul_succ a b : a * succ b = a * b + a`\n\nD'autres théorèmes sur les naturels, comme `zero_mul`,\nsont prouvés par induction à partir de ces deux théorèmes de base.", - "`Add a b`, with notation `a + b`, is\nthe usual sum of natural numbers. Internally it is defined\nvia the following two hypotheses:\n\n* `add_zero a : a + 0 = a`\n\n* `add_succ a b : a + succ b = succ (a + b)`\n\nOther theorems about naturals, such as `zero_add a : 0 + a = a`, are proved\nby induction using these two basic theorems.\"": - "`Add a b`, avec la notation `a + b`, est\nla somme habituelle des nombres naturels. En interne, elle est définie\npar les deux hypothèses suivantes :\n\n* `add_zero a : a + 0 = a`\n\n* `add_succ a b : a + succ b = succ (a + b)`\n\nD'autres théorèmes sur les naturels, comme `zero_add a : 0 + a = a`, sont prouvés\npar induction en utilisant ces deux théorèmes de base.\"", + "`Add a b`, with notation `a + b`, is\nthe usual sum of natural numbers. Internally it is defined\nvia the following two hypotheses:\n\n* `add_zero a : a + 0 = a`\n\n* `add_succ a b : a + succ b = succ (a + b)`\n\nOther theorems about naturals, such as `zero_add a : 0 + a = a`, are proved\nby induction using these two basic theorems.": + "`Add a b`, avec la notation `a + b`, est\nla somme habituelle des nombres naturels. En interne, elle est définie\npar les deux hypothèses suivantes :\n\n* `add_zero a : a + 0 = a`\n\n* `add_succ a b : a + succ b = succ (a + b)`\n\nD'autres théorèmes sur les naturels, comme `zero_add a : 0 + a = a`, sont prouvés\npar induction en utilisant ces deux théorèmes de base.", "[final boss music]": "[musique de boss final]", "[dramatic music]. Now are you ready to face the first boss of the game?": "[musique dramatique]. Êtes-vous maintenant prêt à affronter le premier boss du jeu ?", "[boss battle music]\n\nLook in your inventory to see the proofs you have available.\nThese should be enough.": "[musique de combat de boss]\n\nRegardez dans votre inventaire les preuves dont vous disposez.\nCela devrait suffire.", - "You've now seen all the tactics you need to beat the final boss of the game.\nYou can begin the journey towards this boss by entering Multiplication World.\n\nOr you can go off the beaten track and learn some new tactics in Implication\nWorld. These tactics let you prove more facts about addition, such as\nhow to deduce `a = 0` from `x + a = x`.\n\nClick \"Leave World\" and make your choice.": + "You've now seen all the tactics you need to beat the final boss of the game.\nYou can begin the journey towards this boss by entering Multiplication World.\n\nOr you can go off the beaten track and learn some new tactics in Implication\nWorld. These tactics let you prove more facts about addition, such as\nhow to deduce `a = 0` from `x + a = x`.\n\nClick \"Home\" and make your choice.": "Vous avez maintenant vu toutes les tactiques nécessaires pour vaincre le boss final du jeu.\nVous pouvez commencer le voyage vers ce boss en entrant dans le monde de la Multiplication.\n\nOu vous pouvez sortir des sentiers battus et apprendre de nouvelles tactiques dans le monde\nde l'Implication. Ces tactiques vous permettent de prouver plus de résultats sur l'addition, comme\ncomment déduire `a = 0` de `x + a = x`.\n\nCliquez sur \"Quitter le monde\" et faites votre choix.", "You want to use `add_right_eq_zero`, which you already\nproved, but you'll have to start with `symm at` your hypothesis.": "Vous voulez utiliser `add_right_eq_zero`, que vous avez déjà\nprouvé, mais vous devrez commencer par `symm at` votre hypothèse.", @@ -315,7 +315,7 @@ "We know `zero_ne_succ n` is a proof of `0 = succ n → False` -- but what\nif we have a hypothesis `succ n = 0`? It's the wrong way around!\n\nThe `symm` tactic changes a goal `x = y` to `y = x`, and a goal `x ≠ y`\nto `y ≠ x`. And `symm at h`\ndoes the same for a hypothesis `h`. We've proved $0 \\neq 1$ and called\nthe proof `zero_ne_one`; now try proving $1 \\neq 0$.": "Nous savons que `zero_ne_succ n` est une preuve de `0 = succ n → False` -- mais que faire\nsi nous avons une hypothèse `succ n = 0` ? C'est dans le mauvais sens !\n\nLa tactique `symm` change un but `x = y` en `y = x`, et un but `x ≠ y`\nen `y ≠ x`. Et `symm at h`\nfait la même chose pour une hypothèse `h`. Nous avons prouvé $0 \\neq 1$ et nous avions appelé\nla preuve `zero_ne_one` ; maintenant essayez de prouver $1 \\neq 0$.", "We have seen how to `apply` theorems and assumptions\nof the form `P → Q`. But what if our *goal* is of the form `P → Q`?\nTo prove this goal, we need to know how to say \"let's assume `P` and deduce `Q`\"\nin Lean. We do this with the `intro` tactic.": - "Nous avons vu comment utilsier `apply` sur des théorèmes et des hypothèses\nde la forme `P → Q`. Mais que faire si notre *but* est de la forme `P → Q` ?\nPour prouver ce but, nous devons savoir dire \"supposons `P` et déduisons `Q`\"\ndans Lean. Nous faisons cela avec la tactique `intro`.", + "Nous avons vu comment utiliser `apply` sur des théorèmes et des hypothèses\nde la forme `P → Q`. Mais que faire si notre *but* est de la forme `P → Q` ?\nPour prouver ce but, nous devons savoir dire \"supposons `P` et déduisons `Q`\"\ndans Lean. Nous faisons cela avec la tactique `intro`.", "We gave a pretty unsatisfactory proof of `2 + 2 ≠ 5` earlier on; now give a nicer one.": "Nous avons donné une preuve assez peu satisfaisante de `2 + 2 ≠ 5` plus tôt ; maintenant donnez-en une meilleure.", "We don't know whether to go left or right yet. So start with `cases «{h}» with hx hy`.": @@ -344,7 +344,7 @@ "Ce monde introduit l'exponentiation. Si vous voulez définir `37 ^ n`\nalors, comme toujours, vous devrez savoir ce que vaut `37 ^ 0`, et\nce que vaut `37 ^ (succ d)`, sachant seulement `37 ^ d`.\n\nVous pouvez probablement deviner les noms des théorèmes généraux :\n\n * `pow_zero (a : ℕ) : a ^ 0 = 1`\n * `pow_succ (a b : ℕ) : a ^ succ b = a ^ b * a`\n\nEn utilisant uniquement ceux-ci, pourrez-vous passer le niveau boss final ?\n\nLes niveaux de ce monde ont été conçus par Sian Carey, une étudiante UROP\nà l'Imperial College de Londres, financée par une bourse Mary Lister McCammon\ndurant l'été 2019. Merci à Sian et également à Imperial\nCollege pour l'avoir financée.", "This time, use the `left` tactic.": "Cette fois, utilisez la tactique `left`.", - "This state is not provable! Did you maybe use `rw [add_left_eq_self] at h`\ninstead of `apply [add_left_eq_self] at h`? You can complare the two in the inventory.": + "This state is not provable! Did you maybe use `rw [add_left_eq_self] at h`\ninstead of `apply [add_left_eq_self] at h`? You can compare the two in the inventory.": "Cet état n'est pas prouvable ! Avez-vous peut-être utilisé `rw [add_left_eq_self] at h`\nau lieu de `apply [add_left_eq_self] at h` ? Vous pouvez comparer les deux dans l'inventaire.", "This level proves that if `a ≠ 0` and `b ≠ 0` then `a * b ≠ 0`. One strategy\nis to write both `a` and `b` as `succ` of something, deduce that `a * b` is\nalso `succ` of something, and then `apply zero_ne_succ`.": "Ce niveau prouve que si `a ≠ 0` et `b ≠ 0` alors `a * b ≠ 0`. Une stratégie\nconsiste à écrire `a` et `b` comme `succ` de quelque chose, à déduire que `a * b` est\naussi `succ` de quelque chose, puis à `apply zero_ne_succ`.", @@ -522,7 +522,7 @@ "Notez que `succ a + «{d}»` signifie `(succ a) + «{d}»`. Placez votre curseur\nsur n'importe quel `succ` dans le but ou les hypothèses pour voir exactement ce qu'il prend.", "Nice! You've proved `succ_inj`!\nLet's now prove Peano's other axiom, that successors can't be $0$.": "Bien ! Vous avez prouvé `succ_inj` !\nProuvons maintenant l'autre axiome de Peano, que les successeurs ne peuvent pas être $0$.", - "Nice!\n\nThe next step in the development of order theory is to develop\nthe theory of the interplay between `≤` and multiplication.\nIf you've already done Multiplication World, you're now ready for\nAdvanced Multiplication World. Click on \"Leave World\" to access it.": + "Nice!\n\nThe next step in the development of order theory is to develop\nthe theory of the interplay between `≤` and multiplication.\nIf you've already done Multiplication World, you're now ready for\nAdvanced Multiplication World. Click on \"Home\" to access it.": "Bien !\n\nLa prochaine étape dans le développement de la théorie de l'ordre est de développer\nla théorie de l'interaction entre `≤` et la multiplication.\nSi vous avez déjà fait le monde de la Multiplication, vous êtes maintenant prêt pour\nle monde de la Multiplication Avancée. Cliquez sur \"Quitter le monde\" pour y accéder.", "Nice!": "Bien !", "Next turn `1` into `succ 0` with `rw [one_eq_succ_zero]`.": @@ -531,7 +531,7 @@ "My proof:\n```\ncases h with d hd\nuse d * t\nrw [hd, add_mul]\nrfl\n```": "Ma preuve :\n```\ncases h with d hd\nuse d * t\nrw [hd, add_mul]\nrfl\n```", "Multiplication usually makes a number bigger, but multiplication by zero can make\nit smaller. Thus many lemmas about inequalities and multiplication need the\nhypothesis `a ≠ 0`. Here is a key lemma that enables us to use this hypothesis.\nTo help us with the proof, we can use the `tauto` tactic. Click on the tactic's name\non the right to see what it does.": - "La multiplication transforme généralement un nombre en un noùmbre plus grand, mais la multiplication par zéro peut le rendre\nplus petit. Ainsi, de nombreux lemmes sur les inégalités et la multiplication nécessitent l'\nhypothèse `a ≠ 0`. Voici un lemme clé qui nous permet d'utiliser cette hypothèse.\nPour la preuve, nous pouvons utiliser la tactique `tauto`. Cliquez sur le nom de la tactique\nà droite pour voir ce qu'elle fait.", + "La multiplication transforme généralement un nombre en un nombre plus grand, mais la multiplication par zéro peut le rendre\nplus petit. Ainsi, de nombreux lemmes sur les inégalités et la multiplication nécessitent l'\nhypothèse `a ≠ 0`. Voici un lemme clé qui nous permet d'utiliser cette hypothèse.\nPour la preuve, nous pouvons utiliser la tactique `tauto`. Cliquez sur le nom de la tactique\nà droite pour voir ce qu'elle fait.", "Multiplication is distributive over addition on the left.\nIn other words, for all natural numbers $a$, $b$ and $c$, we have\n$a(b + c) = ab + ac$.": "La multiplication est distributive sur l'addition à gauche.\nAutrement dit, pour tous les nombres naturels $a$, $b$ et $c$, nous avons\n$a(b + c) = ab + ac$.", "Multiplication is commutative.": "La multiplication est commutative.", @@ -608,7 +608,7 @@ "If you have completed Algorithm World then you can use the `contrapose!` tactic\nhere. If not then I'll talk you through a manual approach.": "Si vous avez terminé le monde Algorithmique, vous pouvez utiliser la tactique `contrapose!`\nici. Sinon, je vais vous guider à travers une approche manuelle.", "If you `use` the wrong number, you get stuck with a goal you can't prove.\nWhat number will you `use` here?": - "Si vous utiliser `use` avec le mauvais nombre, vous restez bloqué avec un but que vous ne pourrez pas prouver.\nQuel nombre allez-vous choisir ici ?", + "Si vous utilisez `use` avec le mauvais nombre, vous restez bloqué avec un but que vous ne pourrez pas prouver.\nQuel nombre allez-vous choisir ici ?", "If the goal is not *exactly* a hypothesis, we can sometimes\nuse rewrites to fix things up.": "Si le but n'est pas *exactement* une hypothèse, nous pouvons parfois\nutiliser des réécritures pour arranger les choses.", "If `h` is a proof of `X = Y` then `rw [h]` will\nturn `X`s into `Y`s. But what if we want to\nturn `Y`s into `X`s? To tell the `rw` tactic\nwe want this, we use a left arrow `←`. Type\n`\\l` and then hit the space bar to get this arrow.\n\nLet's prove that $2$ is the number after the number\nafter $0$ again, this time by changing `succ (succ 0)`\ninto `2`.": @@ -663,7 +663,7 @@ "Comment devrions-nous définir `37 * x` ? Tout comme pour l'addition, nous devons donner des définitions\nlorsque $x=0$ et lorsque $x$ est un successeur.\n\nLe cas zéro est facile : nous définissons `37 * 0` comme `0`. Maintenant, disons que nous connaissons\n`37 * d`. Que devrait être `37 * succ d` ? Eh bien, c'est $(d+1)$ fois $37$,\ndonc cela devrait être `37 * d + 37`.\n\nVoici les définitions dans Lean.\n\n * `mul_zero a : a * 0 = 0`\n * `mul_succ a d : a * succ d = a * d + a`\n\nDans ce monde, nous devons non seulement prouver des faits sur la multiplication comme `a * b = b * a`,\nmais aussi des faits sur la façon dont la multiplication interagit avec l'addition, comme `a * (b + c) = a * b + a * c`.\nCommençons.", "How about this for a proof:\n```\nrepeat rw [add_comm n]\nexact add_right_cancel a b n\n```": "Que pensez-vous de cette preuve :\n```\nrepeat rw [add_comm n]\nexact add_right_cancel a b n\n```", - "How about this for a proof:\n\n```\nrw [add_comm]\nexact add_right_eq_zero b a\n```\n\nThat's the end of Advanced Addition World! You'll need these theorems\nfor the next world, `≤` World. Click on \"Leave World\" to access it.": + "How about this for a proof:\n\n```\nrw [add_comm]\nexact add_right_eq_zero b a\n```\n\nThat's the end of Advanced Addition World! You'll need these theorems\nfor the next world, `≤` World. Click on \"Home\" to access it.": "Que pensez-vous de cette preuve :\n\n```\nrw [add_comm]\nexact add_right_eq_zero b a\n```\n\nC'est la fin du monde de l'Addition Avancée ! Vous aurez besoin de ces théorèmes\npour le prochain monde, le monde `≤`. Cliquez sur \"Quitter le monde\" pour y accéder.", "Here's what I was thinking of:\n```\napply mul_left_ne_zero at h\napply one_le_of_ne_zero at h\napply mul_le_mul_right 1 b a at h\nrw [one_mul, mul_comm] at h\nexact h\n```": "Voici ce que j'avais en tête :\n```\napply mul_left_ne_zero at h\napply one_le_of_ne_zero at h\napply mul_le_mul_right 1 b a at h\nrw [one_mul, mul_comm] at h\nexact h\n```", @@ -677,7 +677,7 @@ "Voici ma solution :\n```\ninduction c with d hd\nrw [add_zero, mul_zero, add_zero]\nrfl\nrw [add_succ, mul_succ, hd, mul_succ, add_assoc]\nrfl\n```\n\nL'induction sur `a` ou `b` fonctionne aussi, mais pourrait prendre plus de temps à écrire.", "Here's my proof:\n```\nrw [mul_comm, mul_add]\nrepeat rw [mul_comm c]\nrfl\n```": "Voici ma preuve :\n```\nrw [mul_comm, mul_add]\nrepeat rw [mul_comm c]\nrfl\n```", - "Here's my proof:\n```\nintro h\nrw [add_succ, add_succ, add_zero] at h\nrepeat apply succ_inj at h\napply zero_ne_succ at h\nexact h\n```\n\nEven though Lean is a theorem prover, right now it's pretty clear that we have not\ndeveloped enough material to make it an adequate calculator. In Algorithm\nWorld, a more computer-sciency world, we will develop machinery which makes\nquestions like this much easier, and goals like $20 + 20 ≠ 41$ feasible.\nAlternatively you can do more mathematics in Advanced Addition World, where we prove\nthe lemmas needed to get a working theory of inequalities. Click \"Leave World\" and\ndecide your route.": + "Here's my proof:\n```\nintro h\nrw [add_succ, add_succ, add_zero] at h\nrepeat apply succ_inj at h\napply zero_ne_succ at h\nexact h\n```\n\nEven though Lean is a theorem prover, right now it's pretty clear that we have not\ndeveloped enough material to make it an adequate calculator. In Algorithm\nWorld, a more computer-sciency world, we will develop machinery which makes\nquestions like this much easier, and goals like $20 + 20 ≠ 41$ feasible.\nAlternatively you can do more mathematics in Advanced Addition World, where we prove\nthe lemmas needed to get a working theory of inequalities. Click \"Home\" and\ndecide your route.": "Voici ma preuve :\n```\nintro h\nrw [add_succ, add_succ, add_zero] at h\nrepeat apply succ_inj at h\napply zero_ne_succ at h\nexact h\n```\n\nBien que Lean soit un prouveur de théorèmes, il est clair que nous n'avons pas\ndéveloppé suffisamment de matériel pour en faire une calculatrice adéquate. Dans le monde Algorithmique,\nun monde plus informatique, nous développerons des mécanismes qui rendent\ndes questions comme celle-ci beaucoup plus faciles, et des buts comme $20 + 20 ≠ 41$ réalisables.\nAlternativement, vous pouvez faire plus de mathématiques dans le monde de l'Addition Avancée, où nous prouvons\nles lemmes nécessaires pour obtenir une théorie opérationnelle des inégalités. Cliquez sur \"Quitter le monde\" et\ndécidez de votre route.", "Here's my proof:\n```\ncases x with y\nleft\nrfl\nrw [one_eq_succ_zero] at hx ⊢\napply succ_le_succ at hx\napply le_zero at hx\nrw [hx]\nright\nrfl\n```\n\nIf you solved this level then you should be fine with the next level!": "Voici ma preuve :\n```\ncases x with y\nleft\nrfl\nrw [one_eq_succ_zero] at hx ⊢\napply succ_le_succ at hx\napply le_zero at hx\nrw [hx]\nright\nrfl\n```\n\nSi vous avez résolu ce niveau, vous devriez vous en sortir avec le niveau suivant !", @@ -697,7 +697,7 @@ "Ici, nous voulons traiter les cas `b = 0` et `b ≠ 0` séparément,\ndonc commencez par `cases b with d`.", "Here we begin to\ndevelop an algorithm which, given two naturals `a` and `b`, returns the answer\nto \"does `a = b`?\"\n\nHere is the algorithm. First note that `a` and `b` are numbers, and hence\nare either `0` or successors.\n\n*) If `a` and `b` are both `0`, return \"yes\".\n\n*) If one is `0` and the other is `succ n`, return \"no\".\n\n*) If `a = succ m` and `b = succ n`, then return the answer to \"does `m = n`?\"\n\nOur job now is to *prove* that this algorithm always gives the correct answer. The proof that\n`0 = 0` is `rfl`. The proof that `0 ≠ succ n` is `zero_ne_succ n`, and the proof\nthat `succ m ≠ 0` is `succ_ne_zero m`. The proof that if `h : m = n` then\n`succ m = succ n` is `rw [h]` and then `rfl`. This level is a proof of the one\nremaining job we have to do: if `a ≠ b` then `succ a ≠ succ b`.": "Ici, nous commençons à\ndévelopper un algorithme qui, étant donnés deux naturels `a` et `b`, renvoie la réponse\nà \"`a = b` ?\"\n\nVoici l'algorithme. D'abord, notez que `a` et `b` sont des nombres, et donc\nsont soit `0` soit des successeurs.\n\n*) Si `a` et `b` sont tous deux `0`, renvoyer \"oui\".\n\n*) Si l'un est `0` et l'autre est `succ n`, renvoyer \"non\".\n\n*) Si `a = succ m` et `b = succ n`, alors renvoyer la réponse à \"`m = n` ?\"\n\nNotre travail maintenant est de *prouver* que cet algorithme donne toujours la bonne réponse. La preuve de\n`0 = 0` est `rfl`. La preuve que `0 ≠ succ n` est `zero_ne_succ n`, et la preuve\nque `succ m ≠ 0` est `succ_ne_zero m`. La preuve que si `h : m = n` alors\n`succ m = succ n` est `rw [h]` puis `rfl`. Ce niveau est une preuve de la seule\ntâche restante que nous devons faire : si `a ≠ b` alors `succ a ≠ succ b`.", - "Here is an example proof of 2+2=4 showing off various techniques.\n\n```lean\nnth_rewrite 2 [two_eq_succ_one] -- only change the second `2` to `succ 1`.\nrw [add_succ]\nrw [one_eq_succ_zero]\nrw [add_succ, add_zero] -- two rewrites at once\nrw [← three_eq_succ_two] -- change `succ 2` to `3`\nrw [← four_eq_succ_three]\nrfl\n```\n\nOptional extra: you can run this proof yourself. Switch the game into \"Editor mode\" by clicking\non the `` button in the top right. You can now see your proof\nwritten as several lines of code. Move your cursor between lines to see\nthe goal state at any point. Now cut and paste your code elsewhere if you\nwant to save it, and paste the above proof in instead. Move your cursor\naround to investigate. When you've finished, click the `>_` button in the top right to\nmove back into \"Typewriter mode\".\n\nYou have finished tutorial world!\nClick \"Leave World\" to go back to the\noverworld, and select Addition World, where you will learn\nabout the `induction` tactic.": + "Here is an example proof of 2+2=4 showing off various techniques.\n\n```lean\nnth_rewrite 2 [two_eq_succ_one] -- only change the second `2` to `succ 1`.\nrw [add_succ]\nrw [one_eq_succ_zero]\nrw [add_succ, add_zero] -- two rewrites at once\nrw [← three_eq_succ_two] -- change `succ 2` to `3`\nrw [← four_eq_succ_three]\nrfl\n```\n\nOptional extra: you can run this proof yourself. Switch the game into \"Editor mode\" by clicking\non the `` button in the top right. You can now see your proof\nwritten as several lines of code. Move your cursor between lines to see\nthe goal state at any point. Now cut and paste your code elsewhere if you\nwant to save it, and paste the above proof in instead. Move your cursor\naround to investigate. When you've finished, click the `>_` button in the top right to\nmove back into \"Typewriter mode\".\n\nYou have finished tutorial world!\nClick \"Home\" to go back to the\noverworld, and select Addition World, where you will learn\nabout the `induction` tactic.": "Voici un exemple de preuve de 2+2=4 montrant diverses techniques.\n\n```lean\nnth_rewrite 2 [two_eq_succ_one] -- ne change que le deuxième `2` en `succ 1`\nrw [add_succ]\nrw [one_eq_succ_zero]\nrw [add_succ, add_zero] -- deux réécritures en une fois\nrw [← three_eq_succ_two] -- change `succ 2` en `3`\nrw [← four_eq_succ_three]\nrfl\n```\n\nOption supplémentaire : vous pouvez exécuter cette preuve vous-même. Passez le jeu en \"Mode Éditeur\" en cliquant\nsur le bouton `` en haut à droite. Vous pouvez maintenant voir votre preuve\nécrite sous forme de plusieurs lignes de code. Déplacez votre curseur entre les lignes pour voir\nl'état du but à tout moment. Maintenant, copiez et collez votre code ailleurs si vous\nvoulez le sauvegarder, et collez la preuve ci-dessus à la place. Déplacez votre curseur\nautour pour examiner. Lorsque vous avez terminé, cliquez sur le bouton `>_` en haut à droite pour\nrevenir en \"Mode Machine à écrire\".\n\nVous avez terminé le monde tutoriel !\nCliquez sur \"Quitter le monde\" pour revenir au\nmonde principal, et sélectionnez Addition World, où vous apprendrez\nla tactique `induction`.", "Having to rearrange variables manually using commutativity and\nassociativity is very tedious. We start by reminding you of this. `add_left_comm`\nis a key component in the first algorithm which we'll explain, but we need\nto prove it manually.\n\nRemember that you can do precision commutativity rewriting\nwith things like `rw [add_comm b c]`. And remember that\n`a + b + c` means `(a + b) + c`.": "Devoir réarranger manuellement les variables en utilisant la commutativité et\nl'associativité est très fastidieux. Nous commençons par vous le rappeler. `add_left_comm`\nest un composant clé du premier algorithme que nous expliquerons, mais nous devons\nd'abord le prouver manuellement.\n\nRappelez-vous que vous pouvez faire des réécritures de commutativité précises\navec des choses comme `rw [add_comm b c]`. Et rappelez-vous que\n`a + b + c` signifie `(a + b) + c`.", @@ -739,7 +739,7 @@ "Pour tous les nombres naturels $a$ et $b$, nous avons\n$(\\operatorname{succ}\\ a) \\times b = a\\times b + b$.", "First execute `rw [h]` to replace the `y` with `x + 7`.": "Commencez par exécuter `rw [h]` pour remplacer `y` par `x + 7`.", - "Finally use a targetted `add_comm` to switch `b` and `d`": + "Finally use a targeted `add_comm` to switch `b` and `d`": "Enfin, utilisez un `add_comm` ciblé pour échanger `b` et `d`", "Fermat's Last Theorem": "Grand théorème de Fermat", "Every number in Lean is either $0$ or a successor. We know how to add $0$,\nbut we need to figure out how to add successors. Let's say we already know\nthat `37 + d = q`. What should the answer to `37 + succ d` be? Well,\n`succ d` is one bigger than `d`, so `37 + succ d` should be `succ q`,\nthe number one bigger than `q`. More generally `x + succ d` should\nbe `succ (x + d)`. Let's add this as a lemma.\n\n* `add_succ x d : x + succ d = succ (x + d)`\n\nIf you ever see `... + succ ...` in your goal, `rw [add_succ]` is\nnormally a good idea.\n\nLet's now prove that `succ n = n + 1`. Figure out how to get `+ succ` into\nthe picture, and then `rw [add_succ]`. Switch between the `+` (addition) and\n`012` (numerals) tabs under \"Theorems\" on the right to\nsee which proofs you can rewrite.": @@ -807,8 +807,8 @@ "2 + 2 ≠ 5": "2 + 2 ≠ 5", "1 ≠ 0": "1 ≠ 0", "0 ≤ x": "0 ≤ x", - "*Game version: 4.3*\n\n*Recent additions: bug fixes*\n\n## Progress saving\n\nThe game stores your progress in your local browser storage.\nIf you delete it, your progress will be lost!\n\nWarning: In most browsers, deleting cookies will also clear the local storage\n(or \"local site data\"). Make sure to download your game progress first!\n\n## Credits\n\n* **Creators:** Kevin Buzzard, Jon Eugster\n* **Original Lean3-version:** Kevin Buzzard, Mohammad Pedramfar\n* **Game Engine:** Alexander Bentkamp, Jon Eugster, Patrick Massot\n* **Additional levels:** Sian Carey, Ivan Farabella, Archie Browne.\n* **Additional thanks:** All the student beta testers, all the schools\nwho invited Kevin to speak, and all the schoolkids who asked him questions\nabout the material.\n\n## Resources\n\n* The [Lean Zulip chat](https://leanprover.zulipchat.com/) forum\n* [Original Lean3 version](https://www.ma.imperial.ac.uk/~buzzard/xena/natural_number_game/) (no longer maintained)\n\n## Problems?\n\nPlease ask any questions about this game in the\n[Lean Zulip chat](https://leanprover.zulipchat.com/) forum, for example in\nthe stream \"New Members\". The community will happily help. Note that\nthe Lean Zulip chat is a professional research forum.\nPlease use your full real name there, stay on topic, and be nice. If you're\nlooking for somewhere less formal (e.g. you want to post natural number\ngame memes) then head on over to the [Lean Discord](https://discord.gg/WZ9bs9UCvx).\n\nAlternatively, if you experience issues / bugs you can also open github issues:\n\n* For issues with the game engine, please open an\n[issue at the lean4game](https://github.com/leanprover-community/lean4game/issues) repo.\n* For issues about the game's content, please open an\n[issue at the NNG](https://github.com/hhu-adam/NNG4/issues) repo.": - "*Version du jeu : 4.3*\n\n*Ajouts récents : corrections de bugs*\n\n## Sauvegarde de la progression\n\nLe jeu stocke votre progression dans le stockage local de votre navigateur.\nSi vous le supprimez, votre progression sera perdue !\n\nAvertissement : Dans la plupart des navigateurs, supprimer les cookies effacera également le stockage local\n(ou \"données locales du site\"). Assurez-vous de télécharger d'abord votre progression dans le jeu !\n\n## Crédits\n\n* **Créateurs :** Kevin Buzzard, Jon Eugster\n* **Version Lean3 originale :** Kevin Buzzard, Mohammad Pedramfar\n* **Moteur de jeu :** Alexander Bentkamp, Jon Eugster, Patrick Massot\n* **Niveaux supplémentaires :** Sian Carey, Ivan Farabella, Archie Browne.\n* **Remerciements supplémentaires :** Tous les bêta-testeurs étudiants, toutes les écoles\nqui ont invité Kevin à parler, et tous les écoliers qui lui ont posé des questions\nsur le contenu.\n\n## Ressources\n\n* Le forum [Lean Zulip chat](https://leanprover.zulipchat.com/)\n* [Version Lean3 originale](https://www.ma.imperial.ac.uk/~buzzard/xena/natural_number_game/) (non maintenue)\n\n## Problèmes ?\n\nVeuillez poser toute question sur ce jeu dans le forum\n[Lean Zulip chat](https://leanprover.zulipchat.com/), par exemple dans\nle flux \"New Members\". La communauté se fera un plaisir d'aider. Notez que\nle chat Lean Zulip est un forum de recherche professionnel.\nVeuillez utiliser votre vrai nom complet, rester sur le sujet et être courtois. Si vous\ncherchez un endroit moins formel (par exemple pour poster des mèmes sur le jeu des nombres naturels),\nrendez-vous sur le [Discord Lean](https://discord.gg/WZ9bs9UCvx).\n\nAlternativement, si vous rencontrez des problèmes/bugs, vous pouvez ouvrir des issues GitHub :\n\n* Pour les problèmes liés au moteur de jeu, veuillez ouvrir une issue\n[sur le dépôt lean4game](https://github.com/leanprover-community/lean4game/issues).\n* Pour les problèmes liés au contenu du jeu, veuillez ouvrir une issue\n[sur le dépôt NNG](https://github.com/hhu-adam/NNG4/issues).", + "*Game version: 4.3*\n\n*Recent additions: bug fixes*\n\n## Progress saving\n\nThe game stores your progress in your local browser storage.\nIf you delete it, your progress will be lost!\n\nWarning: In most browsers, deleting cookies will also clear the local storage\n(or \"local site data\"). Make sure to download your game progress first!\n\n## Credits\n\n* **Creators:** Kevin Buzzard, Jon Eugster\n* **Original Lean3-version:** Kevin Buzzard, Mohammad Pedramfar\n* **Game Engine:** Alexander Bentkamp, Jon Eugster, Patrick Massot\n* **Additional levels:** Sian Carey, Ivan Farabella, Archie Browne.\n* **Additional thanks:** All the student beta testers, all the schools\nwho invited Kevin to speak, and all the schoolkids who asked him questions\nabout the material.\n\n## Resources\n\n* The [Lean Zulip chat](https://leanprover.zulipchat.com/) forum\n* [Original Lean3 version](https://github.com/ImperialCollegeLondon/natural_number_game/) (no longer maintained)\n\n## Problems?\n\nPlease ask any questions about this game in the\n[Lean Zulip chat](https://leanprover.zulipchat.com/) forum, for example in\nthe stream \"New Members\". The community will happily help. Note that\nthe Lean Zulip chat is a professional research forum.\nPlease use your full real name there, stay on topic, and be nice. If you're\nlooking for somewhere less formal (e.g. you want to post natural number\ngame memes) then head on over to the [Lean Discord](https://discord.gg/WZ9bs9UCvx).\n\nAlternatively, if you experience issues / bugs you can also open github issues:\n\n* For issues with the game engine, please open an\n[issue at the lean4game](https://github.com/leanprover-community/lean4game/issues) repo.\n* For issues about the game's content, please open an\n[issue at the NNG](https://github.com/hhu-adam/NNG4/issues) repo.": + "*Version du jeu : 4.3*\n\n*Ajouts récents : corrections de bugs*\n\n## Sauvegarde de la progression\n\nLe jeu stocke votre progression dans le stockage local de votre navigateur.\nSi vous le supprimez, votre progression sera perdue !\n\nAvertissement : Dans la plupart des navigateurs, supprimer les cookies effacera également le stockage local\n(ou \"données locales du site\"). Assurez-vous de télécharger d'abord votre progression dans le jeu !\n\n## Crédits\n\n* **Créateurs :** Kevin Buzzard, Jon Eugster\n* **Version Lean3 originale :** Kevin Buzzard, Mohammad Pedramfar\n* **Moteur de jeu :** Alexander Bentkamp, Jon Eugster, Patrick Massot\n* **Niveaux supplémentaires :** Sian Carey, Ivan Farabella, Archie Browne.\n* **Remerciements supplémentaires :** Tous les bêta-testeurs étudiants, toutes les écoles\nqui ont invité Kevin à parler, et tous les écoliers qui lui ont posé des questions\nsur le contenu.\n\n## Ressources\n\n* Le forum [Lean Zulip chat](https://leanprover.zulipchat.com/)\n* [Version Lean3 originale](https://github.com/ImperialCollegeLondon/natural_number_game/) (non maintenue)\n\n## Problèmes ?\n\nVeuillez poser toute question sur ce jeu dans le forum\n[Lean Zulip chat](https://leanprover.zulipchat.com/), par exemple dans\nle flux \"New Members\". La communauté se fera un plaisir d'aider. Notez que\nle chat Lean Zulip est un forum de recherche professionnel.\nVeuillez utiliser votre vrai nom complet, rester sur le sujet et être courtois. Si vous\ncherchez un endroit moins formel (par exemple pour poster des mèmes sur le jeu des nombres naturels),\nrendez-vous sur le [Discord Lean](https://discord.gg/WZ9bs9UCvx).\n\nAlternativement, si vous rencontrez des problèmes/bugs, vous pouvez ouvrir des issues GitHub :\n\n* Pour les problèmes liés au moteur de jeu, veuillez ouvrir une issue\n[sur le dépôt lean4game](https://github.com/leanprover-community/lean4game/issues).\n* Pour les problèmes liés au contenu du jeu, veuillez ouvrir une issue\n[sur le dépôt NNG](https://github.com/hhu-adam/NNG4/issues).", "$x=37\\implies x=37$.": "$x=37\\implies x=37$.", "$x+y=x\\implies y=0$.": "$x+y=x\\implies y=0$.", "$x+1=y+1 \\implies x=y$.": "$x+1=y+1 \\implies x=y$.", @@ -835,7 +835,7 @@ "## Summary\n\n`repeat t` repeatedly applies the tactic `t`\nto the goal. You don't need to use this\ntactic, it just speeds things up sometimes.\n\n## Example\n\n`repeat rw [add_zero]` will turn the goal\n`a + 0 + (0 + (0 + 0)) = b + 0 + 0`\ninto the goal\n`a = b`.": "## Résumé\n\n`repeat t` applique répétitivement la tactique `t`\nau but. Vous n'avez pas besoin d'utiliser cette\ntactique, elle accélère simplement les choses parfois.\n\n## Exemple\n\n`repeat rw [add_zero]` transformera le but\n`a + 0 + (0 + (0 + 0)) = b + 0 + 0`\nen le but\n`a = b`.", "## Summary\n\nThe `use` tactic makes progress with goals which claim something *exists*.\nIf the goal claims that some `x` exists with some property, and you know\nthat `x = 37` will work, then `use 37` will make progress.\n\nBecause `a ≤ b` is notation for \\\"there exists `c` such that `b = a + c`\\\",\nyou can make progress on goals of the form `a ≤ b` by `use`ing the\nnumber which is morally `b - a` (i.e. `use b - a`)\n\nAny of the following examples is possible assuming the type of the argument passed to the `use` function is accurate:\n\n- `use 37`\n- `use a`\n- `use a * a + 1`": - "## Résumé\n\nLa tactique `use` fait progresser les buts qui affirement que quelque chose *existe*.\nSi le but affirme qu'un certain `x` existe avec une certaine propriété, et que vous savez\nque `x = 37` fonctionnera, alors `use 37` fera progresser.\n\nComme `a ≤ b` est une notation pour \"il existe `c` tel que `b = a + c`\",\nvous pouvez faire progresser les buts de la forme `a ≤ b` en utilisant `use` avec le\nnombre qui moralement est `b - a` (c'est-à-dire `use b - a`)\n\nTous les exemples suivants sont possibles en supposant que le type de l'argument passé à la fonction `use` est correct :\n\n- `use 37`\n- `use a`\n- `use a * a + 1`", + "## Résumé\n\nLa tactique `use` fait progresser les buts qui affirment que quelque chose *existe*.\nSi le but affirme qu'un certain `x` existe avec une certaine propriété, et que vous savez\nque `x = 37` fonctionnera, alors `use 37` fera progresser.\n\nComme `a ≤ b` est une notation pour \"il existe `c` tel que `b = a + c`\",\nvous pouvez faire progresser les buts de la forme `a ≤ b` en utilisant `use` avec le\nnombre qui moralement est `b - a` (c'est-à-dire `use b - a`)\n\nTous les exemples suivants sont possibles en supposant que le type de l'argument passé à la fonction `use` est correct :\n\n- `use 37`\n- `use a`\n- `use a * a + 1`", "## Summary\n\nThe `symm` tactic will change a goal or hypothesis of\nthe form `X = Y` to `Y = X`. It will also work on `X ≠ Y`\nand on `X ↔ Y`.\n\n### Example\n\nIf the goal is `2 + 2 = 4` then `symm` will change it to `4 = 2 + 2`.\n\n### Example\n\nIf `h : 2 + 2 ≠ 5` then `symm at h` will change `h` to `5 ≠ 2 + 2`.": "## Résumé\n\nLa tactique `symm` changera un but ou une hypothèse de\nla forme `X = Y` en `Y = X`. Elle fonctionnera aussi sur `X ≠ Y`\net sur `X ↔ Y`.\n\n### Exemple\n\nSi le but est `2 + 2 = 4` alors `symm` le changera en `4 = 2 + 2`.\n\n### Exemple\n\nSi `h : 2 + 2 ≠ 5` alors `symm at h` changera `h` en `5 ≠ 2 + 2`.", "## Summary\n\nIf the goal is a statement `P`, then `exact h` will close the goal if `h` is a proof of `P`.\n\n### Example\n\nIf the goal is `x = 37` and you have a hypothesis `h : x = 37`\nthen `exact h` will solve the goal.\n\n### Example\n\nIf the goal is `x + 0 = x` then `exact add_zero x` will close the goal.\n\n### Exact needs to be exactly right\n\nNote that `exact add_zero` will *not work* in the previous example;\nfor `exact h` to work, `h` has to be *exactly* a proof of the goal.\n`add_zero` is a proof of `∀ n, n + 0 = n` or, if you like,\na proof of `? + 0 = ?` where `?` needs to be supplied by the user.\nThis is in contrast to `rw` and `apply`, which will \\\"guess the inputs\\\"\nif necessary. If the goal is `x + 0 = x` then `rw [add_zero]`\nand `rw [add_zero x]` will both change the goal to `x = x`,\nbecause `rw` guesses the input to the function `add_zero`.": @@ -848,7 +848,7 @@ "## Résumé\n\nSi `n` est un nombre, `cases n with d` scindera le but en deux sous-buts :\nun avec `n = 0` et l'autre avec `n = succ d`.\n\nSi `h` est une preuve (par exemple une hypothèse), `cases h with...` décomposera\nla preuve en ses éléments constitutifs.\n\n## Exemple\n\nSi `n : ℕ` est un nombre, `cases n with d` scindera le but en deux sous-buts :\nun où `n` est remplacé par 0 et l'autre où `n` est remplacé par `succ d`.\nCela correspond à l'idée mathématique que tout nombre naturel est soit `0`\nsoit un successeur.\n\n## Exemple\n\nSi `h : P ∨ Q` est une hypothèse, `cases h with hp hq` transformera un but\nen deux buts : un avec l'hypothèse `hp : P` et l'autre avec l'hypothèse `hq : Q`.\n\n## Exemple\n\nSi `h : False` est une hypothèse, `cases h` fera disparaître le but actuel,\ncar il n'existe aucun moyen de construire une preuve de `False` ! Et s'il ne reste\naucun but, vous avez terminé le niveau.\n\n## Exemple\n\nSi `h : a ≤ b` est une hypothèse, `cases h with c hc` créera un nouveau nombre `c`\net une preuve `hc : b = a + c`. Ceci parce que la *définition* de `a ≤ b` est\n`∃ c, b = a + c`.", "## Summary\n\nIf `n : ℕ` is an object, and the goal mentions `n`, then `induction n with d hd`\nattempts to prove the goal by induction on `n`, with the inductive\nvariable in the successor case being `d`, and the inductive hypothesis being `hd`.\n\n### Example:\nIf the goal is\n```\n0 + n = n\n```\n\nthen\n\n`induction n with d hd`\n\nwill turn it into two goals. The first is `0 + 0 = 0`;\nthe second has an assumption `hd : 0 + d = d` and goal\n`0 + succ d = succ d`.\n\nNote that you must prove the first\ngoal before you can access the second one.": "## Résumé\n\nSi `n : ℕ` est un objet, et que le but mentionne `n`, alors `induction n with d hd`\ntente de prouver le but par induction sur `n` (c'est-à-dire par récurrence sur `n`). avec la variable inductive\ndans le cas successeur étant `d`, et l'hypothèse inductive étant `hd`.\n\n### Exemple :\nSi le but est\n```\n0 + n = n\n```\n\nalors\n\n`induction n with d hd`\n\nle transformera en deux buts. Le premier est `0 + 0 = 0` ;\nle second a une hypothèse `hd : 0 + d = d` et un but\n`0 + succ d = succ d`.\n\nNotez que vous devez prouver le premier\nbut avant de pouvoir accéder au second.", - "## Summary\n\nIf `h` is a proof of an equality `X = Y`, then `rw [h]` will change\nall `X`s in the goal to `Y`s. It's the way to \\\"substitute in\\\".\n\n## Variants\n\n* `rw [← h]` (changes `Y`s to `X`s; get the back arrow by typing `\\left ` or `\\l`.)\n\n* `rw [h1, h2]` (a sequence of rewrites)\n\n* `rw [h] at h2` (changes `X`s to `Y`s in hypothesis `h2`)\n\n* `rw [h] at h1 h2 ⊢` (changes `X`s to `Y`s in two hypotheses and the goal;\nget the `⊢` symbol with `\\|-`.)\n\n* `repeat rw [add_zero]` will keep changing `? + 0` to `?`\nuntil there are no more matches for `? + 0`.\n\n* `nth_rewrite 2 [h]` will change only the second `X` in the goal to `Y`.\n\n### Example:\n\nIf you have the assumption `h : x = y + y` and your goal is\n```\nsucc (x + 0) = succ (y + y)\n```\n\nthen\n\n`rw [add_zero]`\n\nwill change the goal into `succ x = succ (y + y)`, and then\n\n`rw [h]`\n\nwill change the goal into `succ (y + y) = succ (y + y)`, which\ncan be solved with `rfl`.\n\n### Example:\n\nYou can use `rw` to change a hypothesis as well.\nFor example, if you have two hypotheses\n```\nh1 : x = y + 3\nh2 : 2 * y = x\n```\nthen `rw [h1] at h2` will turn `h2` into `h2 : 2 * y = y + 3`.\n\n## Common errors\n\n* You need the square brackets. `rw h` is never correct.\n\n* If `h` is not a *proof* of an *equality* (a statement of the form `A = B`),\nfor example if `h` is a function or an implication,\nthen `rw` is not the tactic you want to use. For example,\n`rw [P = Q]` is never correct: `P = Q` is the theorem *statement*,\nnot the proof. If `h : P = Q` is the proof, then `rw [h]` will work.\n\n## Details\n\nThe `rw` tactic is a way to do \\\"substituting in\\\". There\nare two distinct situations where you can use this tactic.\n\n1) Basic usage: if `h : A = B` is an assumption or\nthe proof of a theorem, and if the goal contains one or more `A`s, then `rw [h]`\nwill change them all to `B`s. The tactic will error\nif there are no `A`s in the goal.\n\n2) Advanced usage: Assumptions coming from theorem proofs\noften have missing pieces. For example `add_zero`\nis a proof that `? + 0 = ?` because `add_zero` really is a function,\nand `?` is the input. In this situation `rw` will look through the goal\nfor any subterm of the form `x + 0`, and the moment it\nfinds one it fixes `?` to be `x` then changes all `x + 0`s to `x`s.\n\nExercise: think about why `rw [add_zero]` changes the term\n`(0 + 0) + (x + 0) + (0 + 0) + (x + 0)` to\n`0 + (x + 0) + 0 + (x + 0)`\n\nIf you can't remember the name of the proof of an equality, look it up in\nthe list of lemmas on the right.\n\n## Targetted usage\n\nIf your goal is `b + c + a = b + (a + c)` and you want to rewrite `a + c`\nto `c + a`, then `rw [add_comm]` will not work because Lean finds another\naddition first and swaps those inputs instead. Use `rw [add_comm a c]` to\nguarantee that Lean rewrites `a + c` to `c + a`. This works because\n`add_comm` is a proof that `?1 + ?2 = ?2 + ?1`, `add_comm a` is a proof\nthat `a + ? = ? + a`, and `add_comm a c` is a proof that `a + c = c + a`.\n\nIf `h : X = Y` then `rw [h]` will turn all `X`s into `Y`s.\nIf you only want to change the 37th occurrence of `X`\nto `Y` then do `nth_rewrite 37 [h]`.": + "## Summary\n\nIf `h` is a proof of an equality `X = Y`, then `rw [h]` will change\nall `X`s in the goal to `Y`s. It's the way to \\\"substitute in\\\".\n\n## Variants\n\n* `rw [← h]` (changes `Y`s to `X`s; get the back arrow by typing `\\left ` or `\\l`.)\n\n* `rw [h1, h2]` (a sequence of rewrites)\n\n* `rw [h] at h2` (changes `X`s to `Y`s in hypothesis `h2`)\n\n* `rw [h] at h1 h2 ⊢` (changes `X`s to `Y`s in two hypotheses and the goal;\nget the `⊢` symbol with `\\|-`.)\n\n* `repeat rw [add_zero]` will keep changing `? + 0` to `?`\nuntil there are no more matches for `? + 0`.\n\n* `nth_rewrite 2 [h]` will change only the second `X` in the goal to `Y`.\n\n### Example:\n\nIf you have the assumption `h : x = y + y` and your goal is\n```\nsucc (x + 0) = succ (y + y)\n```\n\nthen\n\n`rw [add_zero]`\n\nwill change the goal into `succ x = succ (y + y)`, and then\n\n`rw [h]`\n\nwill change the goal into `succ (y + y) = succ (y + y)`, which\ncan be solved with `rfl`.\n\n### Example:\n\nYou can use `rw` to change a hypothesis as well.\nFor example, if you have two hypotheses\n```\nh1 : x = y + 3\nh2 : 2 * y = x\n```\nthen `rw [h1] at h2` will turn `h2` into `h2 : 2 * y = y + 3`.\n\n## Common errors\n\n* You need the square brackets. `rw h` is never correct.\n\n* If `h` is not a *proof* of an *equality* (a statement of the form `A = B`),\nfor example if `h` is a function or an implication,\nthen `rw` is not the tactic you want to use. For example,\n`rw [P = Q]` is never correct: `P = Q` is the theorem *statement*,\nnot the proof. If `h : P = Q` is the proof, then `rw [h]` will work.\n\n## Details\n\nThe `rw` tactic is a way to do \\\"substituting in\\\". There\nare two distinct situations where you can use this tactic.\n\n1) Basic usage: if `h : A = B` is an assumption or\nthe proof of a theorem, and if the goal contains one or more `A`s, then `rw [h]`\nwill change them all to `B`s. The tactic will error\nif there are no `A`s in the goal.\n\n2) Advanced usage: Assumptions coming from theorem proofs\noften have missing pieces. For example `add_zero`\nis a proof that `? + 0 = ?` because `add_zero` really is a function,\nand `?` is the input. In this situation `rw` will look through the goal\nfor any subterm of the form `x + 0`, and the moment it\nfinds one it fixes `?` to be `x` then changes all `x + 0`s to `x`s.\n\nExercise: think about why `rw [add_zero]` changes the term\n`(0 + 0) + (x + 0) + (0 + 0) + (x + 0)` to\n`0 + (x + 0) + 0 + (x + 0)`\n\nIf you can't remember the name of the proof of an equality, look it up in\nthe list of lemmas on the right.\n\n## Targeted usage\n\nIf your goal is `b + c + a = b + (a + c)` and you want to rewrite `a + c`\nto `c + a`, then `rw [add_comm]` will not work because Lean finds another\naddition first and swaps those inputs instead. Use `rw [add_comm a c]` to\nguarantee that Lean rewrites `a + c` to `c + a`. This works because\n`add_comm` is a proof that `?1 + ?2 = ?2 + ?1`, `add_comm a` is a proof\nthat `a + ? = ? + a`, and `add_comm a c` is a proof that `a + c = c + a`.\n\nIf `h : X = Y` then `rw [h]` will turn all `X`s into `Y`s.\nIf you only want to change the 37th occurrence of `X`\nto `Y` then do `nth_rewrite 37 [h]`.": "## Résumé\n\nSi `h` est une preuve d'une égalité `X = Y`, alors `rw [h]` changera\ntous les `X` du but en `Y`. `rw` est l’abréviation de \"rewrite\". C'est la manière de \"substituer\".\n\n## Variantes\n\n* `rw [← h]` (change les `Y` en `X` ; obtenez la flèche gauche en tapant `\\left ` ou `\\l`.)\n\n* `rw [h1, h2]` (une séquence de réécritures)\n\n* `rw [h] at h2` (change les `X` en `Y` dans l'hypothèse `h2`)\n\n* `rw [h] at h1 h2 ⊢` (change les `X` en `Y` dans deux hypothèses et le but ;\nobtenez le symbole `⊢` avec `\\|-`.)\n\n* `repeat rw [add_zero]` continuera à changer `? + 0` en `?`\njusqu'à ce qu'il n'y ait plus de correspondances pour `? + 0`.\n\n* `nth_rewrite 2 [h]` ne changera que le deuxième `X` du but en `Y`.\n\n### Exemple :\n\nSi vous avez l'hypothèse `h : x = y + y` et que votre but est\n```\nsucc (x + 0) = succ (y + y)\n```\n\nalors\n\n`rw [add_zero]`\n\nchangera le but en `succ x = succ (y + y)`, puis\n\n`rw [h]`\n\nchangera le but en `succ (y + y) = succ (y + y)`, ce qui\npeut être résolu avec `rfl`.\n\n### Exemple :\n\nVous pouvez également utiliser `rw` pour changer une hypothèse.\nPar exemple, si vous avez deux hypothèses\n```\nh1 : x = y + 3\nh2 : 2 * y = x\n```\nalors `rw [h1] at h2` transformera `h2` en `h2 : 2 * y = y + 3`.\n\n## Erreurs courantes\n\n* Vous avez besoin des crochets. `rw h` n'est jamais valide.\n\n* Si `h` n'est pas une *preuve* d'une *égalité* (un énoncé de la forme `A = B`),\npar exemple si `h` est une fonction ou une implication,\nalors `rw` n'est pas la tactique que vous voulez utiliser. Par exemple,\n`rw [P = Q]` n'est jamais correct : `P = Q` est l'*énoncé* du théorème,\npas la preuve. Si `h : P = Q` est la preuve, alors `rw [h]` fonctionnera.\n\n## Détails\n\nLa tactique `rw` est un moyen de faire une \"substitution\". Il y a\ndeux situations distinctes où vous pouvez utiliser cette tactique.\n\n1) Utilisation basique : si `h : A = B` est une hypothèse ou\nla preuve d'un théorème, et si le but contient un ou plusieurs `A`, alors `rw [h]`\nles changera tous en `B`. La tactique échouera\ns'il n'y a pas de `A` dans le but.\n\n2) Utilisation avancée : Les hypothèses provenant de preuves de théorèmes\nont souvent des parties manquantes. Par exemple, `add_zero`\nest une preuve que `? + 0 = ?` car `add_zero` est en fait une fonction,\net `?` est l'entrée. Dans cette situation, `rw` parcourra le but\nà la recherche de tout sous-terme de la forme `x + 0`, et dès qu'il\nen trouve un, il fixe `?` à `x` puis change tous les `x + 0` en `x`.\n\nExercice : réfléchissez à pourquoi `rw [add_zero]` change le terme\n`(0 + 0) + (x + 0) + (0 + 0) + (x + 0)` en\n`0 + (x + 0) + 0 + (x + 0)`\n\nSi vous ne vous souvenez pas du nom de la preuve d'une égalité, cherchez-la dans\nla liste des lemmes à droite.\n\n## Utilisation ciblée\n\nSi votre but est `b + c + a = b + (a + c)` et que vous voulez réécrire `a + c`\nen `c + a`, alors `rw [add_comm]` ne fonctionnera pas car Lean trouve d'abord\nune autre addition et échange ces entrées à la place. Utilisez `rw [add_comm a c]` pour\ngarantir que Lean réécrit `a + c` en `c + a`. Cela fonctionne car\n`add_comm` est une preuve que `?1 + ?2 = ?2 + ?1`, `add_comm a` est une preuve\nque `a + ? = ? + a`, et `add_comm a c` est une preuve que `a + c = c + a`.\n\nSi `h : X = Y` alors `rw [h]` transformera tous les `X` en `Y`.\nSi vous voulez seulement changer la 37ème occurrence de `X`\nen `Y`, alors faites `nth_rewrite 37 [h]`.", "## Summary\n\nIf `h : X = Y` and there are several `X`s in the goal, then\n`nth_rewrite 3 [h]` will just change the third `X` to a `Y`.\n\n## Example\n\nIf the goal is `2 + 2 = 4` then `nth_rewrite 2 [two_eq_succ_one]`\nwill change the goal to `2 + succ 1 = 4`. In contrast, `rw [two_eq_succ_one]`\nwill change the goal to `succ 1 + succ 1 = 4`.": "## Résumé\n\nSi `h : X = Y` et qu'il y a plusieurs `X` dans le but, alors\n`nth_rewrite 3 [h]` ne changera que le troisième `X` en `Y`.\n\n## Exemple\n\nSi le but est `2 + 2 = 4` alors `nth_rewrite 2 [two_eq_succ_one]`\nchangera le but en `2 + succ 1 = 4`. En revanche, `rw [two_eq_succ_one]`\nchangera le but en `succ 1 + succ 1 = 4`.", diff --git a/.i18n/fr/Game.po b/.i18n/fr/Game.po index 0146f717..5960fc57 100644 --- a/.i18n/fr/Game.po +++ b/.i18n/fr/Game.po @@ -252,7 +252,7 @@ msgid "" "If you can't remember the name of the proof of an equality, look it up in\n" "the list of lemmas on the right.\n" "\n" -"## Targetted usage\n" +"## Targeted usage\n" "\n" "If your goal is `b + c + a = b + (a + c)` and you want to rewrite `a + c`\n" "to `c + a`, then `rw [add_comm]` will not work because Lean finds another\n" @@ -513,7 +513,7 @@ msgstr "" "apparaître dans le jeu des nombres naturels.*" #: Game.Levels.Tutorial.L03two_eq_ss0 -msgid "`one_eq_succ_zero` is a proof of `1 = succ 0`.\"" +msgid "`one_eq_succ_zero` is a proof of `1 = succ 0`." msgstr "`one_eq_succ_zero` est une preuve que `1 = succ 0`." #: Game.Levels.Tutorial.L03two_eq_ss0 @@ -663,7 +663,7 @@ msgid "" "* `add_succ a b : a + succ b = succ (a + b)`\n" "\n" "Other theorems about naturals, such as `zero_add a : 0 + a = a`, are proved\n" -"by induction using these two basic theorems.\"" +"by induction using these two basic theorems." msgstr "" "`Add a b`, avec la notation `a + b`, est\n" "la somme habituelle des nombres naturels. En interne, elle est définie\n" @@ -674,7 +674,7 @@ msgstr "" "* `add_succ a b : a + succ b = succ (a + b)`\n" "\n" "D'autres théorèmes sur les naturels, comme `zero_add a : 0 + a = a`, sont prouvés\n" -"par induction en utilisant ces deux théorèmes de base.\"" +"par induction en utilisant ces deux théorèmes de base." #: Game.Levels.Tutorial.L05add_zero msgid "" @@ -980,7 +980,7 @@ msgid "" "move back into \"Typewriter mode\".\n" "\n" "You have finished tutorial world!\n" -"Click \"Leave World\" to go back to the\n" +"Click \"Home\" to go back to the\n" "overworld, and select Addition World, where you will learn\n" "about the `induction` tactic." msgstr "" @@ -1083,14 +1083,14 @@ msgstr "" #: Game.Levels.Addition.L01zero_add msgid "" -"`zero_add x` is the proof of `0 + x = x`.\n" +"`zero_add n` is the proof of `0 + n = n`.\n" "\n" -"`zero_add` is a `simp` lemma, because replacing `0 + x` by `x`\n" +"`zero_add` is a `simp` lemma, because replacing `0 + n` by `n`\n" "is almost always what you want to do if you're simplifying an expression." msgstr "" -"`zero_add x` est la preuve que `0 + x = x`.\n" +"`zero_add n` est la preuve que `0 + n = n`.\n" "\n" -"`zero_add` est un lemme `simp`, car remplacer `0 + x` par `x`\n" +"`zero_add` est un lemme `simp`, car remplacer `0 + n` par `n`\n" "est presque toujours ce que vous voulez faire si vous simplifiez une expression." #: Game.Levels.Addition.L01zero_add @@ -1285,8 +1285,8 @@ msgstr "" "Cela devrait suffire." #: Game.Levels.Addition.L03add_comm -msgid "`add_comm x y` is a proof of `x + y = y + x`." -msgstr "`add_comm x y` est une preuve de `x + y = y + x`." +msgid "`add_comm a b` is a proof of `a + b = b + a`." +msgstr "`add_comm a b` est une preuve de `a + b = b + a`." #: Game.Levels.Addition.L03add_comm msgid "" @@ -1391,7 +1391,7 @@ msgid "" "You don't need induction. `add_assoc` moves brackets around,\n" "and `add_comm` moves variables around.\n" "\n" -"Remember that you can do more targetted rewrites by\n" +"Remember that you can do more targeted rewrites by\n" "adding explicit variables as inputs to theorems. For example `rw [add_comm b]`\n" "will only do rewrites of the form `b + ? = ? + b`, and `rw [add_comm b c]`\n" "will only do rewrites of the form `b + c = c + b`." @@ -1439,7 +1439,7 @@ msgid "" "World. These tactics let you prove more facts about addition, such as\n" "how to deduce `a = 0` from `x + a = x`.\n" "\n" -"Click \"Leave World\" and make your choice." +"Click \"Home\" and make your choice." msgstr "" "Vous avez maintenant vu toutes les tactiques nécessaires pour vaincre le boss final du jeu.\n" "Vous pouvez commencer le voyage vers ce boss en entrant dans le monde de la Multiplication.\n" @@ -1560,11 +1560,11 @@ msgstr "" #: Game.Levels.Multiplication.L02zero_mul msgid "" -"`zero_mul x` is the proof that `0 * x = 0`.\n" +"`zero_mul m` is the proof that `0 * m = 0`.\n" "\n" "Note: `zero_mul` is a `simp` lemma." msgstr "" -"`zero_mul x` est la preuve que `0 * x = 0`.\n" +"`zero_mul m` est la preuve que `0 * m = 0`.\n" "\n" "Note : `zero_mul` est un lemme `simp`." @@ -1973,7 +1973,7 @@ msgid "" "Note in particular that `0 ^ 0 = 1`." msgstr "" "`Pow a b`, avec la notation `a ^ b`, est l'exponentiation\n" -" habituelle des nombres naturels, c'est à dire `a` puissance `b. En interne, elle est\n" +" habituelle des nombres naturels, c'est à dire `a` puissance `b`. En interne, elle est\n" " définie par deux axiomes :\n" "\n" " * `pow_zero a : a ^ 0 = 1`\n" @@ -2248,7 +2248,7 @@ msgid "" "an interactive textbook which you can read in your browser,\n" "and which explains how to work with many more mathematical concepts in Lean." msgstr "" -"Nous avons maintenant suffisamment de connaissance pour énoncer une version mathématiquement " +"Nous avons maintenant suffisamment de connaissances pour énoncer une version mathématiquement " "exacte, mais un peu\n" "maladroite, du \"grand théorème de Fermat\".\n" "\n" @@ -2787,7 +2787,7 @@ msgid "" "To prove this goal, we need to know how to say \"let's assume `P` and deduce `Q`\"\n" "in Lean. We do this with the `intro` tactic." msgstr "" -"Nous avons vu comment utilsier `apply` sur des théorèmes et des hypothèses\n" +"Nous avons vu comment utiliser `apply` sur des théorèmes et des hypothèses\n" "de la forme `P → Q`. Mais que faire si notre *but* est de la forme `P → Q` ?\n" "Pour prouver ce but, nous devons savoir dire \"supposons `P` et déduisons `Q`\"\n" "dans Lean. Nous faisons cela avec la tactique `intro`." @@ -3108,7 +3108,7 @@ msgid "" "World, a more computer-sciency world, we will develop machinery which makes\n" "questions like this much easier, and goals like $20 + 20 ≠ 41$ feasible.\n" "Alternatively you can do more mathematics in Advanced Addition World, where we prove\n" -"the lemmas needed to get a working theory of inequalities. Click \"Leave World\" and\n" +"the lemmas needed to get a working theory of inequalities. Click \"Home\" and\n" "decide your route." msgstr "" "Voici ma preuve :\n" @@ -3244,7 +3244,7 @@ msgstr "" "gauche." #: Game.Levels.Algorithm.L02add_algo1 -msgid "Finally use a targetted `add_comm` to switch `b` and `d`" +msgid "Finally use a targeted `add_comm` to switch `b` and `d`" msgstr "Enfin, utilisez un `add_comm` ciblé pour échanger `b` et `d`" #: Game.Levels.Algorithm.L02add_algo1 @@ -4114,7 +4114,7 @@ msgid "" "```\n" "\n" "That's the end of Advanced Addition World! You'll need these theorems\n" -"for the next world, `≤` World. Click on \"Leave World\" to access it." +"for the next world, `≤` World. Click on \"Home\" to access it." msgstr "" "Que pensez-vous de cette preuve :\n" "\n" @@ -4171,7 +4171,7 @@ msgid "" msgstr "" "## Résumé\n" "\n" -"La tactique `use` fait progresser les buts qui affirement que quelque chose *existe*.\n" +"La tactique `use` fait progresser les buts qui affirment que quelque chose *existe*.\n" "Si le but affirme qu'un certain `x` existe avec une certaine propriété, et que vous savez\n" "que `x = 37` fonctionnera, alors `use 37` fera progresser.\n" "\n" @@ -4279,7 +4279,7 @@ msgid "" "If you `use` the wrong number, you get stuck with a goal you can't prove.\n" "What number will you `use` here?" msgstr "" -"Si vous utiliser `use` avec le mauvais nombre, vous restez bloqué avec un but que vous ne pourrez " +"Si vous utilisez `use` avec le mauvais nombre, vous restez bloqué avec un but que vous ne pourrez " "pas prouver.\n" "Quel nombre allez-vous choisir ici ?" @@ -4769,7 +4769,7 @@ msgid "" "The next step in the development of order theory is to develop\n" "the theory of the interplay between `≤` and multiplication.\n" "If you've already done Multiplication World, you're now ready for\n" -"Advanced Multiplication World. Click on \"Leave World\" to access it." +"Advanced Multiplication World. Click on \"Home\" to access it." msgstr "" "Bien !\n" "\n" @@ -4982,7 +4982,7 @@ msgid "" "To help us with the proof, we can use the `tauto` tactic. Click on the tactic's name\n" "on the right to see what it does." msgstr "" -"La multiplication transforme généralement un nombre en un noùmbre plus grand, mais la " +"La multiplication transforme généralement un nombre en un nombre plus grand, mais la " "multiplication par zéro peut le rendre\n" "plus petit. Ainsi, de nombreux lemmes sur les inégalités et la multiplication nécessitent l'\n" "hypothèse `a ≠ 0`. Voici un lemme clé qui nous permet d'utiliser cette hypothèse.\n" @@ -5503,7 +5503,7 @@ msgid "" "## Resources\n" "\n" "* The [Lean Zulip chat](https://leanprover.zulipchat.com/) forum\n" -"* [Original Lean3 version](https://www.ma.imperial.ac.uk/~buzzard/xena/natural_number_game/) (no " +"* [Original Lean3 version](https://github.com/ImperialCollegeLondon/natural_number_game/) (no " "longer maintained)\n" "\n" "## Problems?\n" @@ -5550,7 +5550,7 @@ msgstr "" "## Ressources\n" "\n" "* Le forum [Lean Zulip chat](https://leanprover.zulipchat.com/)\n" -"* [Version Lean3 originale](https://www.ma.imperial.ac.uk/~buzzard/xena/natural_number_game/) (non " +"* [Version Lean3 originale](https://github.com/ImperialCollegeLondon/natural_number_game/) (non " "maintenue)\n" "\n" "## Problèmes ?\n" diff --git a/.i18n/it/Game.json b/.i18n/it/Game.json index 65b992c8..1fe5aa5d 100644 --- a/.i18n/it/Game.json +++ b/.i18n/it/Game.json @@ -75,12 +75,12 @@ "`zero_ne_succ n` è la dimostrazione che `0 ≠ succ n`.\n\nIn Lean, `a ≠ b` è *definito come* `a = b → False`. Dunque\n`zero_ne_succ n` è in realtà la dimostrazione di `0 = succ n → False`.\nQui `False` è la proposizione false più banale. Essendo un'implicazione\npuoi applicarla ad una `h` che dimostra `0 = succ n` con `apply zero_ne_succ at h`.", "`zero_ne_one` is a proof of `0 ≠ 1`.": "`zero_ne_one` è la dimostrazione di `0 ≠ 1`.", - "`zero_mul x` is the proof that `0 * x = 0`.\n\nNote: `zero_mul` is a `simp` lemma.": - "`zero_mul x` è la dimostrazione di `0 * x = 0`.\n\nNB: `zero_mul` è un lemma di semplificazione (`simp`).", + "`zero_mul m` is the proof that `0 * m = 0`.\n\nNote: `zero_mul` is a `simp` lemma.": + "`zero_mul m` è la dimostrazione di `0 * m = 0`.\n\nNB: `zero_mul` è un lemma di semplificazione (`simp`).", "`zero_le x` is a proof that `0 ≤ x`.": "`zero_le x` è la dimostrazione che `0 ≤ x`.", - "`zero_add x` is the proof of `0 + x = x`.\n\n`zero_add` is a `simp` lemma, because replacing `0 + x` by `x`\nis almost always what you want to do if you're simplifying an expression.": - "`zero_add x` è la dimostrazione di `0 + x = x`.\n\n`zero_add` è un lemma del tipo `simp` (semplificazione), infatti sostituire `0 + x` con `x`\nè quasi sempre uno dei passi più ovvi della semplificazione di un'espressione.", + "`zero_add n` is the proof of `0 + n = n`.\n\n`zero_add` is a `simp` lemma, because replacing `0 + n` by `n`\nis almost always what you want to do if you're simplifying an expression.": + "`zero_add n` è la dimostrazione di `0 + n = n`.\n\n`zero_add` è un lemma del tipo `simp` (semplificazione), infatti sostituire `0 + n` con `n`\nè quasi sempre uno dei passi più ovvi della semplificazione di un'espressione.", "`xyzzy` is an ancient magic spell, believed to be the origin of the\nmodern word `sorry`. The game won't complain - or notice - if you\nprove anything with `xyzzy`.": "`xyzzy` è un incantesimo arcaico, si crede che sia l'origine\ndella parola inglese `sorry`. Il gioco non si lamenterà - e nemmeno noterà - se\nrisolvi tutti i livelli con `xyzzy`.", "`two_mul m` is the proof that `2 * m = m + m`.": @@ -130,8 +130,8 @@ "`one_mul m` è la dimostrazione che `1 * m = m`.", "`one_le_of_ne_zero a` is a proof that `a ≠ 0 → 1 ≤ a`.": "`one_le_of_ne_zero a` è la dimostrazione che `a ≠ 0 → 1 ≤ a`.", - "`one_eq_succ_zero` is a proof of `1 = succ 0`.\"": - "`one_eq_succ_zero` è la dimostrazione di `1 = succ 0`.\"", + "`one_eq_succ_zero` is a proof of `1 = succ 0`.": + "`one_eq_succ_zero` è la dimostrazione di `1 = succ 0`.", "`nth_rewrite 2 [two_eq_succ_one]` is I think quicker than `rw [two_eq_succ_one]`.": "`nth_rewrite 2 [two_eq_succ_one]` più veloce di `rw [two_eq_succ_one]`, secondo me.", "`mul_zero m` is the proof that `m * 0 = 0`.": @@ -219,9 +219,9 @@ "`add_left_cancel a b n` è il teorema che dice $n+a=n+b\\implies a=b$.\nPuoi dimostrarlo facendo induzione su `n` oppure puoi dedurlo tramite `add_right_cancel`.", "`add_left_cancel a b n` is the theorem that $n+a=n+b \\implies a=b.$": "`add_left_cancel a b n` è il teorema $n+a=n+b \\implies a=b.$", - "`add_comm x y` is a proof of `x + y = y + x`.": - "`add_comm x y` è la dimostrazione di `x + y = y + x`.", - "`add_comm b c` is a proof that `b + c = c + b`. But if your goal\nis `a + b + c = a + c + b` then `rw [add_comm b c]` will not\nwork! Because the goal means `(a + b) + c = (a + c) + b` so there\nis no `b + c` term *directly* in the goal.\n\nUse associativity and commutativity to prove `add_right_comm`.\nYou don't need induction. `add_assoc` moves brackets around,\nand `add_comm` moves variables around.\n\nRemember that you can do more targetted rewrites by\nadding explicit variables as inputs to theorems. For example `rw [add_comm b]`\nwill only do rewrites of the form `b + ? = ? + b`, and `rw [add_comm b c]`\nwill only do rewrites of the form `b + c = c + b`.": + "`add_comm a b` is a proof of `a + b = b + a`.": + "`add_comm a b` è la dimostrazione di `a + b = b + a`.", + "`add_comm b c` is a proof that `b + c = c + b`. But if your goal\nis `a + b + c = a + c + b` then `rw [add_comm b c]` will not\nwork! Because the goal means `(a + b) + c = (a + c) + b` so there\nis no `b + c` term *directly* in the goal.\n\nUse associativity and commutativity to prove `add_right_comm`.\nYou don't need induction. `add_assoc` moves brackets around,\nand `add_comm` moves variables around.\n\nRemember that you can do more targeted rewrites by\nadding explicit variables as inputs to theorems. For example `rw [add_comm b]`\nwill only do rewrites of the form `b + ? = ? + b`, and `rw [add_comm b c]`\nwill only do rewrites of the form `b + c = c + b`.": "`add_comm b c` è una dimostrazione di `b + c = c + b`. Ma se il goal\nè `a + b + c = a + c + b`, `rw [add_comm b c]` non funzionerà!\nQuesto perché il goal sta in realtà per `(a + b) + c = (a + c) + b`, e se guardi bene questo goal non include\nil termine `b + c` *direttamente*.\n\nUsa l'associatività e la commutatività per dimostrare `add_right_comm`.\nNon è necessario procedere per induzione. `add_assoc` sposta le parentesi,\ne `add_comm` sposta le variabili.\n\nRicorda che puoi fare sostituzioni mirate fornendo\nesplicitamente le variabili in input ai teoremi. Ad esempio `rw [add_comm b]`\nfarà solo sostituzioni della forma `b + ? = ? + b`, e `rw [add_comm b c]`\nfarà solo sostituzioni della forma `b + c = c + b`.", "`add_assoc a b c` is a proof\nthat `(a + b) + c = a + (b + c)`. Note that in Lean `(a + b) + c` prints\nas `a + b + c`, because the notation for addition is defined to be left\nassociative.": "`add_assoc a b c` è la dimostrazione\ndi `(a + b) + c = a + (b + c)`. Ricordati che in Lean `(a + b) + c` viene\nstampato come `a + b + c`, perché la notazione dell'addizione è left \nassociative.", @@ -235,14 +235,14 @@ "`Pow a b`, con notazione `a ^ b`, è\n l'elevamento a potenza sui numeri naturali. Dentro Lean è\n definita tramite due assiomi:\n\n * `pow_zero a : a ^ 0 = 1`\n\n * `pow_succ a b : a ^ succ b = a ^ b * a`\n\nIn particolare, dal primo segue che `0 ^ 0 = 1`.", "`Mul a b`, with notation `a * b`, is the usual\n product of natural numbers. Internally it is\n via two axioms:\n\n * `mul_zero a : a * 0 = 0`\n\n * `mul_succ a b : a * succ b = a * b + a`\n\nOther theorems about naturals, such as `zero_mul`,\nare proved by induction from these two basic theorems.": "`Mul a b`, con notazione `a * b`, è il solito\n prodotto tra numeri naturali. Dentro Lean è\n definito tramite due assiomi:\n\n * `mul_zero a : a * 0 = 0`\n\n * `mul_succ a b : a * succ b = a * b + a`\n\nTutti gli altri teoremi sulla moltiplicazione e i naturali, come `zero_mul`,\nsi dimostrano per induzione usando questi due assiomi fondamentali.", - "`Add a b`, with notation `a + b`, is\nthe usual sum of natural numbers. Internally it is defined\nvia the following two hypotheses:\n\n* `add_zero a : a + 0 = a`\n\n* `add_succ a b : a + succ b = succ (a + b)`\n\nOther theorems about naturals, such as `zero_add a : 0 + a = a`, are proved\nby induction using these two basic theorems.\"": - "`Add a b`, con la notazione `a + b`, è\nl'operazione di addizione sui numeri naturali. Dentro Lean è definita\ntramite due ipotesi:\n\n* `add_zero a : a + 0 = a`\n\n* `add_succ a b : a + succ b = succ (a + b)`\n\nGli altri teoremi sui numeri naturali e l'addizione, come `zero_add a : 0 + a = a`, si dimostrano\nper induzione usando questi due teoremi fondamentali.\"", + "`Add a b`, with notation `a + b`, is\nthe usual sum of natural numbers. Internally it is defined\nvia the following two hypotheses:\n\n* `add_zero a : a + 0 = a`\n\n* `add_succ a b : a + succ b = succ (a + b)`\n\nOther theorems about naturals, such as `zero_add a : 0 + a = a`, are proved\nby induction using these two basic theorems.": + "`Add a b`, con la notazione `a + b`, è\nl'operazione di addizione sui numeri naturali. Dentro Lean è definita\ntramite due ipotesi:\n\n* `add_zero a : a + 0 = a`\n\n* `add_succ a b : a + succ b = succ (a + b)`\n\nGli altri teoremi sui numeri naturali e l'addizione, come `zero_add a : 0 + a = a`, si dimostrano\nper induzione usando questi due teoremi fondamentali.", "[final boss music]": "[final boss music]", "[dramatic music]. Now are you ready to face the first boss of the game?": "[musica drammatica] Sei pronto per affrontare il primo boss del gioco?", "[boss battle music]\n\nLook in your inventory to see the proofs you have available.\nThese should be enough.": "[musica da boss battle]\n\nSfrutta le dimostrazioni disponibili nel tuo inventario.\nDovrebbero bastarti.", - "You've now seen all the tactics you need to beat the final boss of the game.\nYou can begin the journey towards this boss by entering Multiplication World.\n\nOr you can go off the beaten track and learn some new tactics in Implication\nWorld. These tactics let you prove more facts about addition, such as\nhow to deduce `a = 0` from `x + a = x`.\n\nClick \"Leave World\" and make your choice.": + "You've now seen all the tactics you need to beat the final boss of the game.\nYou can begin the journey towards this boss by entering Multiplication World.\n\nOr you can go off the beaten track and learn some new tactics in Implication\nWorld. These tactics let you prove more facts about addition, such as\nhow to deduce `a = 0` from `x + a = x`.\n\nClick \"Home\" and make your choice.": "Ora hai incontrato tutte le tattiche che ti servono per sconfiggere il boss finale del gioco.\nPuoi proseguire spedito la tua marcia verso il boss finale passando dal Mondo Moltiplicazione.\n\nOppure puoi fare una deviazione e imparare qualche nuova tattica esotica nel Mondo Implicazione.\nQueste tattiche ti permetteranno di dimostrare altre proprietà dell'addizione, ad esempio\ncome dedurre `a = 0` da `x + a = x`.\n\nPremi \"Abbandona mondo\" e scegli la tua strada.", "You want to use `add_right_eq_zero`, which you already\nproved, but you'll have to start with `symm at` your hypothesis.": "Qui è opportuno usare `add_right_eq_zero`, che hai già\ndimostrato, ma prima dovrai applicare `symm at` su un'ipotesi.", @@ -518,7 +518,7 @@ "Attento che `succ a + «{d}»` sta per `(succ a) + «{d}»`. Sposta il mouse\nsopra `succ` o nel goal o nelle ipotesi per capire su cosa agisce esattamente.", "Nice! You've proved `succ_inj`!\nLet's now prove Peano's other axiom, that successors can't be $0$.": "Bene! Hai dimostrato `succ_inj`!\nOra dimostriamo l'altro assioma di Peano, ossia che un successore non può essere $0$.", - "Nice!\n\nThe next step in the development of order theory is to develop\nthe theory of the interplay between `≤` and multiplication.\nIf you've already done Multiplication World, you're now ready for\nAdvanced Multiplication World. Click on \"Leave World\" to access it.": + "Nice!\n\nThe next step in the development of order theory is to develop\nthe theory of the interplay between `≤` and multiplication.\nIf you've already done Multiplication World, you're now ready for\nAdvanced Multiplication World. Click on \"Home\" to access it.": "Bene!\n\nIl passo successivo nello sviluppo della teoria degli ordini è sviluppare\nla teoria dell'interazione tra `≤` e la moltiplicazione.\nSe hai già fatto il Mondo Moltiplicazione, sei pronto per ascendere al\nMondo Moltiplicazione Avanzata. Clicca su \"Abbandona mondo\" per accedervi.", "Nice!": "Ottimo!", "Next turn `1` into `succ 0` with `rw [one_eq_succ_zero]`.": @@ -657,7 +657,7 @@ "Come si può definire `37 * x`? Come per l'addizione, dobbiamo dare la definizione per\nquando $x=0$ e quando $x$ è un successore.\n\nIl caso di zero è facile: definiamo `37 * 0` uguale a `0`. Ora, immaginiamo di sapere quanto fa\n`37 * d`. Quanto fa allora `37 * succ d`? Beh, non è altro che $37$ sommato a se stesso $(d+1)$ volte,\nquindi `37 * d + 37`.\n\nEcco le due definizioni in Lean.\n\n * `mul_zero a : a * 0 = 0`\n * `mul_succ a d : a * succ d = a * d + a`\n\nIn questo mondo non ci limiteremo a dimostrare fatti riguardanti solo la moltiplicazione come `a * b = b * a`,\nma anche fatti su come la moltiplicazione interagisce con l'addizione, come `a * (b + c) = a * b + a * c`.\nIniziamo!", "How about this for a proof:\n```\nrepeat rw [add_comm n]\nexact add_right_cancel a b n\n```": "Cosa ne pensi di questa dimostrazione:\n```\nrepeat rw [add_comm n]\nexact add_right_cancel a b n\n```", - "How about this for a proof:\n\n```\nrw [add_comm]\nexact add_right_eq_zero b a\n```\n\nThat's the end of Advanced Addition World! You'll need these theorems\nfor the next world, `≤` World. Click on \"Leave World\" to access it.": + "How about this for a proof:\n\n```\nrw [add_comm]\nexact add_right_eq_zero b a\n```\n\nThat's the end of Advanced Addition World! You'll need these theorems\nfor the next world, `≤` World. Click on \"Home\" to access it.": "Come ti sembra questa dimostrazione:\n\n```\nrw [add_comm]\nexact add_right_eq_zero b a\n```\n\nQuesto è tutto per il Mondo Addizione Avanzata! I teoremi di questo mondo ti torneranno utili\nnel prossimo mondo, il Mondo `≤`. Clicca su \"Abbandona mondo\" per navigarci.", "Here's what I was thinking of:\n```\napply mul_left_ne_zero at h\napply one_le_of_ne_zero at h\napply mul_le_mul_right 1 b a at h\nrw [one_mul, mul_comm] at h\nexact h\n```": "Ecco quello che avevo in mente:\n```\napply mul_left_ne_zero at h\napply one_le_of_ne_zero at h\napply mul_le_mul_right 1 b a at h\nrw [one_mul, mul_comm] at h\nexact h\n```", @@ -671,7 +671,7 @@ "Ecco come l'ho fatta io:\n```\ninduction c with d hd\nrw [add_zero, mul_zero, add_zero]\nrfl\nrw [add_succ, mul_succ, hd, mul_succ, add_assoc]\nrfl\n```\n\nSi poteva risolvere anche per induzione su `a` or `b`, ma avrebbe richiesto più passi.", "Here's my proof:\n```\nrw [mul_comm, mul_add]\nrepeat rw [mul_comm c]\nrfl\n```": "Ecco la mia dimostrazione:\n```\nrw [mul_comm, mul_add]\nrepeat rw [mul_comm c]\nrfl\n```", - "Here's my proof:\n```\nintro h\nrw [add_succ, add_succ, add_zero] at h\nrepeat apply succ_inj at h\napply zero_ne_succ at h\nexact h\n```\n\nEven though Lean is a theorem prover, right now it's pretty clear that we have not\ndeveloped enough material to make it an adequate calculator. In Algorithm\nWorld, a more computer-sciency world, we will develop machinery which makes\nquestions like this much easier, and goals like $20 + 20 ≠ 41$ feasible.\nAlternatively you can do more mathematics in Advanced Addition World, where we prove\nthe lemmas needed to get a working theory of inequalities. Click \"Leave World\" and\ndecide your route.": + "Here's my proof:\n```\nintro h\nrw [add_succ, add_succ, add_zero] at h\nrepeat apply succ_inj at h\napply zero_ne_succ at h\nexact h\n```\n\nEven though Lean is a theorem prover, right now it's pretty clear that we have not\ndeveloped enough material to make it an adequate calculator. In Algorithm\nWorld, a more computer-sciency world, we will develop machinery which makes\nquestions like this much easier, and goals like $20 + 20 ≠ 41$ feasible.\nAlternatively you can do more mathematics in Advanced Addition World, where we prove\nthe lemmas needed to get a working theory of inequalities. Click \"Home\" and\ndecide your route.": "Ecco la mia dimostrazione:\n```\nintro h\nrw [add_succ, add_succ, add_zero] at h\nrepeat apply succ_inj at h\napply zero_ne_succ at h\nexact h\n```\n\nLean è un theorem prover, ma non abbiamo ancora parlato del fatto che può anche fungere da linguaggio di programmazione. Nel Mondo Algoritmi,\nun mondo dal carattere più informatico, svilupperemo programmi per automatizzare le\ndimostrazioni, grazie ai quali potremo dimostrare $20 + 20 ≠ 41$ senza diventare matti.\nIn alternativa, puoi proseguire lungo il filo matematico nel Mondo Addizione Avanzata, dove dimostreremo\ni lemmi che supportano la teoria delle disuguaglianze. Clicca su \"Abbandona mondo\" e\nscegli la tua strada.", "Here's my proof:\n```\ncases x with y\nleft\nrfl\nrw [one_eq_succ_zero] at hx ⊢\napply succ_le_succ at hx\napply le_zero at hx\nrw [hx]\nright\nrfl\n```\n\nIf you solved this level then you should be fine with the next level!": "Ecco la mia dimostrazione:\n```\ncases x with y\nleft\nrfl\nrw [one_eq_succ_zero] at hx ⊢\napply succ_le_succ at hx\napply le_zero at hx\nrw [hx]\nright\nrfl\n```\n\nSe hai risolto questo livello allora puoi risolvere tranquillamente anche il successivo!", @@ -691,7 +691,7 @@ "Qui vogliamo ragionare separatamente con i due casi `b = 0` e `b ≠ 0`,\nquindi parti con `cases b with d`.", "Here we begin to\ndevelop an algorithm which, given two naturals `a` and `b`, returns the answer\nto \"does `a = b`?\"\n\nHere is the algorithm. First note that `a` and `b` are numbers, and hence\nare either `0` or successors.\n\n*) If `a` and `b` are both `0`, return \"yes\".\n\n*) If one is `0` and the other is `succ n`, return \"no\".\n\n*) If `a = succ m` and `b = succ n`, then return the answer to \"does `m = n`?\"\n\nOur job now is to *prove* that this algorithm always gives the correct answer. The proof that\n`0 = 0` is `rfl`. The proof that `0 ≠ succ n` is `zero_ne_succ n`, and the proof\nthat `succ m ≠ 0` is `succ_ne_zero m`. The proof that if `h : m = n` then\n`succ m = succ n` is `rw [h]` and then `rfl`. This level is a proof of the one\nremaining job we have to do: if `a ≠ b` then `succ a ≠ succ b`.": "Cominciamo lo sviluppo\ndi un algoritmo che, dati due naturali `a` e`b`, restituisce la risposta\nalla domanda \"does `a = b`?\"\n\nPresentiamo l'algoritmo. Nota prima che `a` e `b` sono entrambi numeri, e dunque\nsono `0` oppure dei successori.\n\n*) Se `a` e `b` sono entrambi `0`, restituiamo \"sì\".\n\n*) Se uno dei due è `0` e l'altro è `succ n`, restituiamo \"no\".\n\n*) Se `a = succ m` e `b = succ n`, restituiamo la risposta a \"`m = n`?\"\n\nNon ci rimane che *dimostrare* che questo algoritmo ci dà sempre la risposta corretta. Procediamo per casi. La dimostrazione di\n`0 = 0` è `rfl`. La dimostrazione di `0 ≠ succ n` è `zero_ne_succ n`, e la dimostrazione di\n`succ m ≠ 0` è `succ_ne_zero m`. La dimostrazione di \"se `h : m = n` allora\n`succ m = succ n`\" è `rw [h]` e infine `rfl`. Questo livello ci salva una parte di\nlavoro per dimostrare: se `a ≠ b` allora `succ a ≠ succ b`.", - "Here is an example proof of 2+2=4 showing off various techniques.\n\n```lean\nnth_rewrite 2 [two_eq_succ_one] -- only change the second `2` to `succ 1`.\nrw [add_succ]\nrw [one_eq_succ_zero]\nrw [add_succ, add_zero] -- two rewrites at once\nrw [← three_eq_succ_two] -- change `succ 2` to `3`\nrw [← four_eq_succ_three]\nrfl\n```\n\nOptional extra: you can run this proof yourself. Switch the game into \"Editor mode\" by clicking\non the `` button in the top right. You can now see your proof\nwritten as several lines of code. Move your cursor between lines to see\nthe goal state at any point. Now cut and paste your code elsewhere if you\nwant to save it, and paste the above proof in instead. Move your cursor\naround to investigate. When you've finished, click the `>_` button in the top right to\nmove back into \"Typewriter mode\".\n\nYou have finished tutorial world!\nClick \"Leave World\" to go back to the\noverworld, and select Addition World, where you will learn\nabout the `induction` tactic.": + "Here is an example proof of 2+2=4 showing off various techniques.\n\n```lean\nnth_rewrite 2 [two_eq_succ_one] -- only change the second `2` to `succ 1`.\nrw [add_succ]\nrw [one_eq_succ_zero]\nrw [add_succ, add_zero] -- two rewrites at once\nrw [← three_eq_succ_two] -- change `succ 2` to `3`\nrw [← four_eq_succ_three]\nrfl\n```\n\nOptional extra: you can run this proof yourself. Switch the game into \"Editor mode\" by clicking\non the `` button in the top right. You can now see your proof\nwritten as several lines of code. Move your cursor between lines to see\nthe goal state at any point. Now cut and paste your code elsewhere if you\nwant to save it, and paste the above proof in instead. Move your cursor\naround to investigate. When you've finished, click the `>_` button in the top right to\nmove back into \"Typewriter mode\".\n\nYou have finished tutorial world!\nClick \"Home\" to go back to the\noverworld, and select Addition World, where you will learn\nabout the `induction` tactic.": "Ecco un esempio di dimostrazione di 2+2=4 che impiega varie tecniche.\n\n```lean\nnth_rewrite 2 [two_eq_succ_one] -- only change the second `2` to `succ 1`.\nrw [add_succ]\nrw [one_eq_succ_zero]\nrw [add_succ, add_zero] -- two rewrites at once\nrw [← three_eq_succ_two] -- change `succ 2` to `3`\nrw [← four_eq_succ_three]\nrfl\n```\n\nEsercizio facoltativo: prova ad eseguire questa dimostrazione. Entra nella \"Modalità editor\" cliccando sul pulsante\n`` in alto a destra. Dovresti vedere la tua dimostrazione estesa su\ndiverse linee di codice. Muovendo il cursore da una linea all'altra vedrai\nlo stato della dimostrazione in ogni punto. Ora copia la tua dimostrazione e salvala da qualche parte per non\nperderla, e incolla la dimostrazione che abbiamo riportato qui sopra al posto del tuo codice. Muovi il cursore\ntra le linee per vedere come si comporta, sperimenta un po' con l'interfaccia. Quando hai finito, premi il pulsante `>_` in alto a destra per\nritornare nella \"Modalità interattiva\".\n\nHai completato il Mondo Tutorial!\nPremi \"Abbandona mondo\" per tornare al \nmenu principale, ed entra nel Mondo Addizione, dove imparerai a usare\nla tattica `induction`.", "Having to rearrange variables manually using commutativity and\nassociativity is very tedious. We start by reminding you of this. `add_left_comm`\nis a key component in the first algorithm which we'll explain, but we need\nto prove it manually.\n\nRemember that you can do precision commutativity rewriting\nwith things like `rw [add_comm b c]`. And remember that\n`a + b + c` means `(a + b) + c`.": "Ricollocare le variabili manualmente usando la commutatività e\nl'associatività è un lavoraccio. Ma possiamo fare di meglio. `add_left_comm`\nè un lemma chiave del primo algoritmo che spiegheremo, ma prima di impiegarlo dobbiamo\ndimostrarlo.\n\nRicorda che puoi applicare la commutatività precisando le \nvariabili che vuoi scambiare, scrivendo tipo `rw [add_comm b c]`. Ricorda anche che\n`a + b + c` sta per `(a + b) + c`.", @@ -733,7 +733,7 @@ "Per tutti i numeri naturali $a$ e $b$, si ha che\n$(\\operatorname{succ}\\ a) \\times b = a\\times b + b$.", "First execute `rw [h]` to replace the `y` with `x + 7`.": "Innanzitutto, esegui `rw [h]` per sostituire `y` con `x + 7`.", - "Finally use a targetted `add_comm` to switch `b` and `d`": + "Finally use a targeted `add_comm` to switch `b` and `d`": "Infine fai un rewrite mirato di `add_comm` per scambiare `b` con `d`", "Fermat's Last Theorem": "L'ultimo teorema di Fermat", "Every number in Lean is either $0$ or a successor. We know how to add $0$,\nbut we need to figure out how to add successors. Let's say we already know\nthat `37 + d = q`. What should the answer to `37 + succ d` be? Well,\n`succ d` is one bigger than `d`, so `37 + succ d` should be `succ q`,\nthe number one bigger than `q`. More generally `x + succ d` should\nbe `succ (x + d)`. Let's add this as a lemma.\n\n* `add_succ x d : x + succ d = succ (x + d)`\n\nIf you ever see `... + succ ...` in your goal, `rw [add_succ]` is\nnormally a good idea.\n\nLet's now prove that `succ n = n + 1`. Figure out how to get `+ succ` into\nthe picture, and then `rw [add_succ]`. Switch between the `+` (addition) and\n`012` (numerals) tabs under \"Theorems\" on the right to\nsee which proofs you can rewrite.": @@ -803,8 +803,8 @@ "2 + 2 ≠ 5": "2 + 2 ≠ 5", "1 ≠ 0": "1 ≠ 0", "0 ≤ x": "0 ≤ x", - "*Game version: 4.3*\n\n*Recent additions: bug fixes*\n\n## Progress saving\n\nThe game stores your progress in your local browser storage.\nIf you delete it, your progress will be lost!\n\nWarning: In most browsers, deleting cookies will also clear the local storage\n(or \"local site data\"). Make sure to download your game progress first!\n\n## Credits\n\n* **Creators:** Kevin Buzzard, Jon Eugster\n* **Original Lean3-version:** Kevin Buzzard, Mohammad Pedramfar\n* **Game Engine:** Alexander Bentkamp, Jon Eugster, Patrick Massot\n* **Additional levels:** Sian Carey, Ivan Farabella, Archie Browne.\n* **Additional thanks:** All the student beta testers, all the schools\nwho invited Kevin to speak, and all the schoolkids who asked him questions\nabout the material.\n\n## Resources\n\n* The [Lean Zulip chat](https://leanprover.zulipchat.com/) forum\n* [Original Lean3 version](https://www.ma.imperial.ac.uk/~buzzard/xena/natural_number_game/) (no longer maintained)\n\n## Problems?\n\nPlease ask any questions about this game in the\n[Lean Zulip chat](https://leanprover.zulipchat.com/) forum, for example in\nthe stream \"New Members\". The community will happily help. Note that\nthe Lean Zulip chat is a professional research forum.\nPlease use your full real name there, stay on topic, and be nice. If you're\nlooking for somewhere less formal (e.g. you want to post natural number\ngame memes) then head on over to the [Lean Discord](https://discord.gg/WZ9bs9UCvx).\n\nAlternatively, if you experience issues / bugs you can also open github issues:\n\n* For issues with the game engine, please open an\n[issue at the lean4game](https://github.com/leanprover-community/lean4game/issues) repo.\n* For issues about the game's content, please open an\n[issue at the NNG](https://github.com/hhu-adam/NNG4/issues) repo.": - "*Versione del gioco: 4.2*\n\n*Aggiunti di recente: rimozione di bug*\n\n## Salvataggio del gioco\n\nIl gioco salva il tuo progresso nella memoria locale del browser.\nSe svuoti la memoria del browser, perderai anche i dati del gioco! (le tue preziose dimostrazioni!)\n\nAttenzione: nella maggior parte dei browser, eliminando i cookies si elimina anche la memoria di un sito\n(o \"i dati locali del sito\"). In ogni caso, assicurati di esportare il tuo progresso del gioco!\n\n## Riconoscimenti\n\n* **Autori:** Kevin Buzzard, Jon Eugster\n* **Versione originale per Lean3:** Kevin Buzzard, Mohammad Pedramfar\n* **Game Engine:** Alexander Bentkamp, Jon Eugster, Patrick Massot\n* **Livelli extra:** Sian Carey, Ivan Farabella, Archie Browne.\n* **Traduzione italiana**: Federico Dal Pio Luogo\n* **Grazie anche a:** Gli studenti che si sono offerti come beta testers, tutte le scuole\nche hanno invitato Kevin a parlare, e gli studenti che gli hanno fatto domande\nsul materiale.\n\n## Risorse\n\n* La [chat di Lean su Zulip](https://leanprover.zulipchat.com/)\n* Il [gioco originale per Lean3](https://www.ma.imperial.ac.uk/~buzzard/xena/natural_number_game/) (no longer maintained)\n\n## Problemi?\n\nRivolgi le tue domande sul gioco nella\n[chat di Lean su Zulip](https://leanprover.zulipchat.com/), utilizzando\nlo stream \"New Members\". I membri della comunità sono felici di aiutare. Nota che\nla chat di Lean su Zulip è un forum professionale di ricerca.\nPerciò usa il tuo nome reale e per intero, rimani in tema, e sii cortese. Se cerchi\nun forum più informale (dove puoi ad esempio postare\ni meme sui numeri naturali) allora il [server Discord di Lean](https://discord.gg/WZ9bs9UCvx) fa per te.\n\nIn alternativa, se il gioco funziona male o dovessi trovare un bug puoi aprire una issue su github:\n\n* Per problemi relativi al game engine, apri una\n[issue sul repo lean4game](https://github.com/leanprover-community/lean4game/issues).\n* Per problemi relativi ai contenuti del the gioco, apri una\n[issue sul repo NNG](https://github.com/hhu-adam/NNG4/issues).", + "*Game version: 4.3*\n\n*Recent additions: bug fixes*\n\n## Progress saving\n\nThe game stores your progress in your local browser storage.\nIf you delete it, your progress will be lost!\n\nWarning: In most browsers, deleting cookies will also clear the local storage\n(or \"local site data\"). Make sure to download your game progress first!\n\n## Credits\n\n* **Creators:** Kevin Buzzard, Jon Eugster\n* **Original Lean3-version:** Kevin Buzzard, Mohammad Pedramfar\n* **Game Engine:** Alexander Bentkamp, Jon Eugster, Patrick Massot\n* **Additional levels:** Sian Carey, Ivan Farabella, Archie Browne.\n* **Additional thanks:** All the student beta testers, all the schools\nwho invited Kevin to speak, and all the schoolkids who asked him questions\nabout the material.\n\n## Resources\n\n* The [Lean Zulip chat](https://leanprover.zulipchat.com/) forum\n* [Original Lean3 version](https://github.com/ImperialCollegeLondon/natural_number_game/) (no longer maintained)\n\n## Problems?\n\nPlease ask any questions about this game in the\n[Lean Zulip chat](https://leanprover.zulipchat.com/) forum, for example in\nthe stream \"New Members\". The community will happily help. Note that\nthe Lean Zulip chat is a professional research forum.\nPlease use your full real name there, stay on topic, and be nice. If you're\nlooking for somewhere less formal (e.g. you want to post natural number\ngame memes) then head on over to the [Lean Discord](https://discord.gg/WZ9bs9UCvx).\n\nAlternatively, if you experience issues / bugs you can also open github issues:\n\n* For issues with the game engine, please open an\n[issue at the lean4game](https://github.com/leanprover-community/lean4game/issues) repo.\n* For issues about the game's content, please open an\n[issue at the NNG](https://github.com/hhu-adam/NNG4/issues) repo.": + "*Versione del gioco: 4.2*\n\n*Aggiunti di recente: rimozione di bug*\n\n## Salvataggio del gioco\n\nIl gioco salva il tuo progresso nella memoria locale del browser.\nSe svuoti la memoria del browser, perderai anche i dati del gioco! (le tue preziose dimostrazioni!)\n\nAttenzione: nella maggior parte dei browser, eliminando i cookies si elimina anche la memoria di un sito\n(o \"i dati locali del sito\"). In ogni caso, assicurati di esportare il tuo progresso del gioco!\n\n## Riconoscimenti\n\n* **Autori:** Kevin Buzzard, Jon Eugster\n* **Versione originale per Lean3:** Kevin Buzzard, Mohammad Pedramfar\n* **Game Engine:** Alexander Bentkamp, Jon Eugster, Patrick Massot\n* **Livelli extra:** Sian Carey, Ivan Farabella, Archie Browne.\n* **Traduzione italiana**: Federico Dal Pio Luogo\n* **Grazie anche a:** Gli studenti che si sono offerti come beta testers, tutte le scuole\nche hanno invitato Kevin a parlare, e gli studenti che gli hanno fatto domande\nsul materiale.\n\n## Risorse\n\n* La [chat di Lean su Zulip](https://leanprover.zulipchat.com/)\n* Il [gioco originale per Lean3](https://github.com/ImperialCollegeLondon/natural_number_game/) (no longer maintained)\n\n## Problemi?\n\nRivolgi le tue domande sul gioco nella\n[chat di Lean su Zulip](https://leanprover.zulipchat.com/), utilizzando\nlo stream \"New Members\". I membri della comunità sono felici di aiutare. Nota che\nla chat di Lean su Zulip è un forum professionale di ricerca.\nPerciò usa il tuo nome reale e per intero, rimani in tema, e sii cortese. Se cerchi\nun forum più informale (dove puoi ad esempio postare\ni meme sui numeri naturali) allora il [server Discord di Lean](https://discord.gg/WZ9bs9UCvx) fa per te.\n\nIn alternativa, se il gioco funziona male o dovessi trovare un bug puoi aprire una issue su github:\n\n* Per problemi relativi al game engine, apri una\n[issue sul repo lean4game](https://github.com/leanprover-community/lean4game/issues).\n* Per problemi relativi ai contenuti del the gioco, apri una\n[issue sul repo NNG](https://github.com/hhu-adam/NNG4/issues).", "$x=37\\implies x=37$.": "$x=37\\implies x=37$.", "$x+y=x\\implies y=0$.": "$x+y=x\\implies y=0$.", "$x+1=y+1 \\implies x=y$.": "$x+1=y+1 \\implies x=y$.", @@ -844,7 +844,7 @@ "## Descrizione\n\nSe `n` è un numero, allora `cases n with d` spezzerà il goal in due goal,\nuno dove `n = 0` e un altro dove `n = succ d`.\n\nSe `h` è una dimostrazione (per esempio tra le ipotesi), allora `cases h with...` spezzerà\nla dimostrazione in tante parti quante quanti i modi di derivare `h`.\n\n## Esempio\n\nSe `n : ℕ` è un numero, allora `cases n with d` spezzerà il goal in due subgoal,\nuno dove `n` è stato rimpiazzato da 0 e l'altro dove `n` è stato rimpiazzato da `succ d`. Questo\ncorrisponde all'intuizione matematica che ogni numero naturale è o `0`\noppure un successore.\n\n## Esempio\n\nSe `h : P ∨ Q` è un'ipotesi, allora `cases h with hp hq` trasformerà il goal\nin due goal, uno con l'ipotesi `hp : P` e l'altro con\nl'ipotesi `hq : Q`.\n\n## Esempio\n\nSe `h : False` è un'ipotesi, allora `cases h` trasformerà il goal in zero goal,\nperché non vi è alcun modo di dimostrare `False`! E se rimani con zero cose da dimostrare\nvuol dire che hai completato il livello.\n\n## Esempio\n\nSe `h : a ≤ b` è un'ipotesi, allora `cases h with c hc` istanzierà un nuovo numero `c`\ne una dimostrazione di `hc : b = a + c`. Questo deriva dalla *definizione* di `a ≤ b`, che è\n`∃ c, b = a + c`.", "## Summary\n\nIf `n : ℕ` is an object, and the goal mentions `n`, then `induction n with d hd`\nattempts to prove the goal by induction on `n`, with the inductive\nvariable in the successor case being `d`, and the inductive hypothesis being `hd`.\n\n### Example:\nIf the goal is\n```\n0 + n = n\n```\n\nthen\n\n`induction n with d hd`\n\nwill turn it into two goals. The first is `0 + 0 = 0`;\nthe second has an assumption `hd : 0 + d = d` and goal\n`0 + succ d = succ d`.\n\nNote that you must prove the first\ngoal before you can access the second one.": "## Descrizione\n\nSe `n : ℕ` è un oggetto, e il goal fa il nome di `n`, allora `induction n with d hd`\navvia la dimostrazione per induzione attorno alla variabile `n`, con la variabile\ninduttiva nel caso del successore chiamata `d` e l'ipotesi induttiva chiamata`hd`.\n\n### Esempio:\nSe il goal è\n```\n0 + n = n\n```\n\nallora\n\n`induction n with d hd`\n\nlo spezzerà in sue sotto-goal. Il primo è `0 + 0 = 0`;\nil secondo porta ha con sé un ipotesi `hd : 0 + d = d` e il goal\n`0 + succ d = succ d`.\n\nTieni presente che devi dimostrare il primo\ngoal prima di avere accesso al secondo.", - "## Summary\n\nIf `h` is a proof of an equality `X = Y`, then `rw [h]` will change\nall `X`s in the goal to `Y`s. It's the way to \\\"substitute in\\\".\n\n## Variants\n\n* `rw [← h]` (changes `Y`s to `X`s; get the back arrow by typing `\\left ` or `\\l`.)\n\n* `rw [h1, h2]` (a sequence of rewrites)\n\n* `rw [h] at h2` (changes `X`s to `Y`s in hypothesis `h2`)\n\n* `rw [h] at h1 h2 ⊢` (changes `X`s to `Y`s in two hypotheses and the goal;\nget the `⊢` symbol with `\\|-`.)\n\n* `repeat rw [add_zero]` will keep changing `? + 0` to `?`\nuntil there are no more matches for `? + 0`.\n\n* `nth_rewrite 2 [h]` will change only the second `X` in the goal to `Y`.\n\n### Example:\n\nIf you have the assumption `h : x = y + y` and your goal is\n```\nsucc (x + 0) = succ (y + y)\n```\n\nthen\n\n`rw [add_zero]`\n\nwill change the goal into `succ x = succ (y + y)`, and then\n\n`rw [h]`\n\nwill change the goal into `succ (y + y) = succ (y + y)`, which\ncan be solved with `rfl`.\n\n### Example:\n\nYou can use `rw` to change a hypothesis as well.\nFor example, if you have two hypotheses\n```\nh1 : x = y + 3\nh2 : 2 * y = x\n```\nthen `rw [h1] at h2` will turn `h2` into `h2 : 2 * y = y + 3`.\n\n## Common errors\n\n* You need the square brackets. `rw h` is never correct.\n\n* If `h` is not a *proof* of an *equality* (a statement of the form `A = B`),\nfor example if `h` is a function or an implication,\nthen `rw` is not the tactic you want to use. For example,\n`rw [P = Q]` is never correct: `P = Q` is the theorem *statement*,\nnot the proof. If `h : P = Q` is the proof, then `rw [h]` will work.\n\n## Details\n\nThe `rw` tactic is a way to do \\\"substituting in\\\". There\nare two distinct situations where you can use this tactic.\n\n1) Basic usage: if `h : A = B` is an assumption or\nthe proof of a theorem, and if the goal contains one or more `A`s, then `rw [h]`\nwill change them all to `B`s. The tactic will error\nif there are no `A`s in the goal.\n\n2) Advanced usage: Assumptions coming from theorem proofs\noften have missing pieces. For example `add_zero`\nis a proof that `? + 0 = ?` because `add_zero` really is a function,\nand `?` is the input. In this situation `rw` will look through the goal\nfor any subterm of the form `x + 0`, and the moment it\nfinds one it fixes `?` to be `x` then changes all `x + 0`s to `x`s.\n\nExercise: think about why `rw [add_zero]` changes the term\n`(0 + 0) + (x + 0) + (0 + 0) + (x + 0)` to\n`0 + (x + 0) + 0 + (x + 0)`\n\nIf you can't remember the name of the proof of an equality, look it up in\nthe list of lemmas on the right.\n\n## Targetted usage\n\nIf your goal is `b + c + a = b + (a + c)` and you want to rewrite `a + c`\nto `c + a`, then `rw [add_comm]` will not work because Lean finds another\naddition first and swaps those inputs instead. Use `rw [add_comm a c]` to\nguarantee that Lean rewrites `a + c` to `c + a`. This works because\n`add_comm` is a proof that `?1 + ?2 = ?2 + ?1`, `add_comm a` is a proof\nthat `a + ? = ? + a`, and `add_comm a c` is a proof that `a + c = c + a`.\n\nIf `h : X = Y` then `rw [h]` will turn all `X`s into `Y`s.\nIf you only want to change the 37th occurrence of `X`\nto `Y` then do `nth_rewrite 37 [h]`.": + "## Summary\n\nIf `h` is a proof of an equality `X = Y`, then `rw [h]` will change\nall `X`s in the goal to `Y`s. It's the way to \\\"substitute in\\\".\n\n## Variants\n\n* `rw [← h]` (changes `Y`s to `X`s; get the back arrow by typing `\\left ` or `\\l`.)\n\n* `rw [h1, h2]` (a sequence of rewrites)\n\n* `rw [h] at h2` (changes `X`s to `Y`s in hypothesis `h2`)\n\n* `rw [h] at h1 h2 ⊢` (changes `X`s to `Y`s in two hypotheses and the goal;\nget the `⊢` symbol with `\\|-`.)\n\n* `repeat rw [add_zero]` will keep changing `? + 0` to `?`\nuntil there are no more matches for `? + 0`.\n\n* `nth_rewrite 2 [h]` will change only the second `X` in the goal to `Y`.\n\n### Example:\n\nIf you have the assumption `h : x = y + y` and your goal is\n```\nsucc (x + 0) = succ (y + y)\n```\n\nthen\n\n`rw [add_zero]`\n\nwill change the goal into `succ x = succ (y + y)`, and then\n\n`rw [h]`\n\nwill change the goal into `succ (y + y) = succ (y + y)`, which\ncan be solved with `rfl`.\n\n### Example:\n\nYou can use `rw` to change a hypothesis as well.\nFor example, if you have two hypotheses\n```\nh1 : x = y + 3\nh2 : 2 * y = x\n```\nthen `rw [h1] at h2` will turn `h2` into `h2 : 2 * y = y + 3`.\n\n## Common errors\n\n* You need the square brackets. `rw h` is never correct.\n\n* If `h` is not a *proof* of an *equality* (a statement of the form `A = B`),\nfor example if `h` is a function or an implication,\nthen `rw` is not the tactic you want to use. For example,\n`rw [P = Q]` is never correct: `P = Q` is the theorem *statement*,\nnot the proof. If `h : P = Q` is the proof, then `rw [h]` will work.\n\n## Details\n\nThe `rw` tactic is a way to do \\\"substituting in\\\". There\nare two distinct situations where you can use this tactic.\n\n1) Basic usage: if `h : A = B` is an assumption or\nthe proof of a theorem, and if the goal contains one or more `A`s, then `rw [h]`\nwill change them all to `B`s. The tactic will error\nif there are no `A`s in the goal.\n\n2) Advanced usage: Assumptions coming from theorem proofs\noften have missing pieces. For example `add_zero`\nis a proof that `? + 0 = ?` because `add_zero` really is a function,\nand `?` is the input. In this situation `rw` will look through the goal\nfor any subterm of the form `x + 0`, and the moment it\nfinds one it fixes `?` to be `x` then changes all `x + 0`s to `x`s.\n\nExercise: think about why `rw [add_zero]` changes the term\n`(0 + 0) + (x + 0) + (0 + 0) + (x + 0)` to\n`0 + (x + 0) + 0 + (x + 0)`\n\nIf you can't remember the name of the proof of an equality, look it up in\nthe list of lemmas on the right.\n\n## Targeted usage\n\nIf your goal is `b + c + a = b + (a + c)` and you want to rewrite `a + c`\nto `c + a`, then `rw [add_comm]` will not work because Lean finds another\naddition first and swaps those inputs instead. Use `rw [add_comm a c]` to\nguarantee that Lean rewrites `a + c` to `c + a`. This works because\n`add_comm` is a proof that `?1 + ?2 = ?2 + ?1`, `add_comm a` is a proof\nthat `a + ? = ? + a`, and `add_comm a c` is a proof that `a + c = c + a`.\n\nIf `h : X = Y` then `rw [h]` will turn all `X`s into `Y`s.\nIf you only want to change the 37th occurrence of `X`\nto `Y` then do `nth_rewrite 37 [h]`.": "## Descrizione\n\nSe `h` è una prova dell'uguaglianza `X = Y`, allora `rw [h]` scriverà\n`Y` al posto di ogni `X` nel goal. `rw` svolge l'operazione di \\\"sostituzione\\\".\n\n## Varianti di `rw`\n\n* `rw [← h]` (riscrive le `Y` con `X`; per avere la freccetta all'indietro si digita `\\left ` oppure `\\l`.)\n\n* `rw [h1, h2]` (sostituzioni in sequenza)\n\n* `rw [h] at h2` (riscrive le `X` in `Y` nell'ipotesi `h2`)\n\n* `rw [h] at h1 h2 ⊢` (riscrive le `X` in `Y` in due ipotesi e nel goal;\nper avere il simbolo `⊢` digita `\\|-`.)\n\n* `repeat rw [add_zero]` riscriverà continuamente `? + 0` in `?`\nfinché non riesce più a trovare espressioni della forma `? + 0`.\n\n* `nth_rewrite 2 [h]` riscriverà solo la seconda `X` nel goal in `Y`.\n\n### Esempio:\n\nSe hai l'ipotesi `h : x = y + y` e il goal è\n```\nsucc (x + 0) = succ (y + y)\n```\n\nallora il comando\n\n`rw [add_zero]`\n\nriscriverà il goal in `succ x = succ (y + y)`, e poi il comando\n\n`rw [h]`\n\nriscriverà il goal in `succ (y + y) = succ (y + y)`, il quale\npuò essere risolto con `rfl`.\n\n### Esempio:\n\n`rw` può anche riscrivere nelle ipotesi.\nAd esempio, se hai le seguenti due ipotesi:\n```\nh1 : x = y + 3\nh2 : 2 * y = x\n```\neseguendo `rw [h1] at h2` sostituirà la `x` dentro `h2`, che diventerà `h2 : 2 * y = y + 3`.\n\n## Errori comuni\n\n* `rw` accetta una lista di teoremi, dunque le parentesi quadre sono sempre da mettere. Scrivere `rw h` è un errore di sintassi.\n\n* Inoltre, gli argomenti che passi a `rw` devono essere *prove* di *uguaglianza*, dunque dei teoremi che hai dimostrato in precedenza e che hanno la forma`A = B`).\nScrivere `rw [P = Q]` è sbagliato: `P = Q` è solo l'*affermazione* dell'uguaglianza,\nnon la sua dimostrazione. Se invece hai `h : P = Q` nel contesto, `h` è una dimostrazione di `P = Q` e allora potrai scrivere `rw [h]`.\n\n## Dettagli\n\n`rw` è la tattica che svolge la \\\"sostituzione\\\". Ci sono due casi in cui può\nessere usata:\n\n1) Uso basilare: se `h : A = B` è un'ipotesi del contesto\noppure la dimostrazione di un teorema, e se il goal contiene una o più `A`, allora `rw [h]`\nle sostituirà tutte con `B`. La tattica darà un errore\nse non ci sono `A` nel goal.\n\n2) Uso avanzato: certi teoremi hanno delle incognite.\n Ad esempio, `add_zero`\npuò essere trattato come un funzione il cui corpo è `? + 0 = ?`\ndove `?` è l'input. Applicando `rw` a `add_zero`, `rw` cercherà all'interno del goal\nun termine della forma `x + 0`; appena lo trova\nfissa l'incognita `?` a `x` e cambierà tutte le occorrenze di `x + 0` a `x`.\n\nEsercizio: prova a spiegare perché `rw [add_zero]` trasforma il termine\n`(0 + 0) + (x + 0) + (0 + 0) + (x + 0)` in\n`0 + (x + 0) + 0 + (x + 0)`\n\nSe non ti ricordi il nome di una dimostrazione di un'uguaglianza, puoi cercarlo\nnell'elenco di lemma sulla destra.\n\n## Uso mirato\n\nSe nel goal hai `b + c + a = b + (a + c)` e vuoi riscrivere solo il termine `a + c`\na `c + a`, invocare semplicemente `rw [add_comm]` non darà il risultato che ti aspetti perché Lean\napplica il teorema sulla prima espressione che ha un match con un'addizione. Puoi usare `rw [add_comm a c]` per\nfar sì che Lean riscriva `a + c` a `c + a`. In questo modo stai fissando le incognite del teorema:\n`add_comm` è la prova di `?1 + ?2 = ?2 + ?1`, `add_comm a` è la prova\ndi `a + ? = ? + a`, e infine `add_comm a c` è la prova di `a + c = c + a`.\n\nData la dimostrazione `h : X = Y`, `rw [h]` riscriverà tutte le `X` a `Y` nel goal.\nPer cambiare solo la trentasettesima occorrenza di `X`\na `Y`, il metodo giusto è `nth_rewrite 37 [h]`.", "## Summary\n\nIf `h : X = Y` and there are several `X`s in the goal, then\n`nth_rewrite 3 [h]` will just change the third `X` to a `Y`.\n\n## Example\n\nIf the goal is `2 + 2 = 4` then `nth_rewrite 2 [two_eq_succ_one]`\nwill change the goal to `2 + succ 1 = 4`. In contrast, `rw [two_eq_succ_one]`\nwill change the goal to `succ 1 + succ 1 = 4`.": "## Descrizione\n\nSe hai `h : X = Y` e nel goal ci sono diverse `X`, con\n`nth_rewrite 3 [h]` puoi cambiare solo la terza `X` in `Y`.\n\n## Esempio\n\nSe il goal è `2 + 2 = 4` allora `nth_rewrite 2 [two_eq_succ_one]`\nsostituirà la seconda occorrenza di `2`, e il goal diventerà `2 + succ 1 = 4`. Invece, il semplice `rw [two_eq_succ_one]`\nsostituirà tutte le occorrenze di `2` e il goal diventerà `succ 1 + succ 1 = 4`.", diff --git a/.i18n/it/Game.po b/.i18n/it/Game.po index b4c73252..9ed3342b 100644 --- a/.i18n/it/Game.po +++ b/.i18n/it/Game.po @@ -239,8 +239,8 @@ msgid "" "questions like this much easier, and goals like $20 + 20 ≠ 41$ feasible.\n" "Alternatively you can do more mathematics in Advanced Addition World, where " "we prove\n" -"the lemmas needed to get a working theory of inequalities. Click \"Leave " -"World\" and\n" +"the lemmas needed to get a working theory of inequalities. Click \"Home\" " +"and\n" "decide your route." msgstr "" "Ecco la mia dimostrazione:\n" @@ -763,8 +763,8 @@ msgid "add_left_comm" msgstr "add_left_comm" #: Game.Levels.Tutorial.L03two_eq_ss0 -msgid "`one_eq_succ_zero` is a proof of `1 = succ 0`.\"" -msgstr "`one_eq_succ_zero` è la dimostrazione di `1 = succ 0`.\"" +msgid "`one_eq_succ_zero` is a proof of `1 = succ 0`." +msgstr "`one_eq_succ_zero` è la dimostrazione di `1 = succ 0`." #: Game.Levels.Power.L02zero_pow_succ msgid "" @@ -1301,7 +1301,7 @@ msgid "" "The next step in the development of order theory is to develop\n" "the theory of the interplay between `≤` and multiplication.\n" "If you've already done Multiplication World, you're now ready for\n" -"Advanced Multiplication World. Click on \"Leave World\" to access it." +"Advanced Multiplication World. Click on \"Home\" to access it." msgstr "" "Bene!\n" "\n" @@ -1655,15 +1655,15 @@ msgstr "" #: Game.Levels.Addition.L01zero_add msgid "" -"`zero_add x` is the proof of `0 + x = x`.\n" +"`zero_add n` is the proof of `0 + n = n`.\n" "\n" -"`zero_add` is a `simp` lemma, because replacing `0 + x` by `x`\n" +"`zero_add` is a `simp` lemma, because replacing `0 + n` by `n`\n" "is almost always what you want to do if you're simplifying an expression." msgstr "" -"`zero_add x` è la dimostrazione di `0 + x = x`.\n" +"`zero_add n` è la dimostrazione di `0 + n = n`.\n" "\n" "`zero_add` è un lemma del tipo `simp` (semplificazione), infatti sostituire " -"`0 + x` con `x`\n" +"`0 + n` con `n`\n" "è quasi sempre uno dei passi più ovvi della semplificazione di " "un'espressione." @@ -2644,7 +2644,7 @@ msgid "" "If you can't remember the name of the proof of an equality, look it up in\n" "the list of lemmas on the right.\n" "\n" -"## Targetted usage\n" +"## Targeted usage\n" "\n" "If your goal is `b + c + a = b + (a + c)` and you want to rewrite `a + c`\n" "to `c + a`, then `rw [add_comm]` will not work because Lean finds another\n" @@ -3310,7 +3310,7 @@ msgid "" "move back into \"Typewriter mode\".\n" "\n" "You have finished tutorial world!\n" -"Click \"Leave World\" to go back to the\n" +"Click \"Home\" to go back to the\n" "overworld, and select Addition World, where you will learn\n" "about the `induction` tactic." msgstr "" @@ -4046,7 +4046,7 @@ msgid "" "```\n" "\n" "That's the end of Advanced Addition World! You'll need these theorems\n" -"for the next world, `≤` World. Click on \"Leave World\" to access it." +"for the next world, `≤` World. Click on \"Home\" to access it." msgstr "" "Come ti sembra questa dimostrazione:\n" "\n" @@ -4251,7 +4251,7 @@ msgstr "" "bisogno di un indizio." #: Game.Levels.Algorithm.L02add_algo1 -msgid "Finally use a targetted `add_comm` to switch `b` and `d`" +msgid "Finally use a targeted `add_comm` to switch `b` and `d`" msgstr "Infine fai un rewrite mirato di `add_comm` per scambiare `b` con `d`" #: Game.Levels.Multiplication.L07mul_add @@ -4618,7 +4618,7 @@ msgid "" "World. These tactics let you prove more facts about addition, such as\n" "how to deduce `a = 0` from `x + a = x`.\n" "\n" -"Click \"Leave World\" and make your choice." +"Click \"Home\" and make your choice." msgstr "" "Ora hai incontrato tutte le tattiche che ti servono per sconfiggere il boss " "finale del gioco.\n" @@ -4989,7 +4989,7 @@ msgid "" "* `add_succ a b : a + succ b = succ (a + b)`\n" "\n" "Other theorems about naturals, such as `zero_add a : 0 + a = a`, are proved\n" -"by induction using these two basic theorems.\"" +"by induction using these two basic theorems." msgstr "" "`Add a b`, con la notazione `a + b`, è\n" "l'operazione di addizione sui numeri naturali. Dentro Lean è definita\n" @@ -5001,7 +5001,7 @@ msgstr "" "\n" "Gli altri teoremi sui numeri naturali e l'addizione, come `zero_add a : 0 + " "a = a`, si dimostrano\n" -"per induzione usando questi due teoremi fondamentali.\"" +"per induzione usando questi due teoremi fondamentali." #: Game.Levels.Implication.L10one_ne_zero msgid "1 ≠ 0" @@ -5049,8 +5049,8 @@ msgid "Multiplication is commutative." msgstr "La moltiplicazione è commutativa." #: Game.Levels.Addition.L03add_comm -msgid "`add_comm x y` is a proof of `x + y = y + x`." -msgstr "`add_comm x y` è la dimostrazione di `x + y = y + x`." +msgid "`add_comm a b` is a proof of `a + b = b + a`." +msgstr "`add_comm a b` è la dimostrazione di `a + b = b + a`." #: Game.Levels.Implication.L02exact2 msgid "" @@ -5720,11 +5720,11 @@ msgstr "livello completato! 🎉" #: Game.Levels.Multiplication.L02zero_mul msgid "" -"`zero_mul x` is the proof that `0 * x = 0`.\n" +"`zero_mul m` is the proof that `0 * m = 0`.\n" "\n" "Note: `zero_mul` is a `simp` lemma." msgstr "" -"`zero_mul x` è la dimostrazione di `0 * x = 0`.\n" +"`zero_mul m` è la dimostrazione di `0 * m = 0`.\n" "\n" "NB: `zero_mul` è un lemma di semplificazione (`simp`)." @@ -6030,7 +6030,7 @@ msgid "" "You don't need induction. `add_assoc` moves brackets around,\n" "and `add_comm` moves variables around.\n" "\n" -"Remember that you can do more targetted rewrites by\n" +"Remember that you can do more targeted rewrites by\n" "adding explicit variables as inputs to theorems. For example `rw [add_comm " "b]`\n" "will only do rewrites of the form `b + ? = ? + b`, and `rw [add_comm b c]`\n" diff --git a/.i18n/pt-BR/Game.json b/.i18n/pt-BR/Game.json new file mode 100644 index 00000000..27df9204 --- /dev/null +++ b/.i18n/pt-BR/Game.json @@ -0,0 +1,689 @@ +{"≤ World": "Mundo do ≤", + "≠": "≠", + "§0.": "§0.", + "§0, with notation §1, is the usual\n product of natural numbers. Internally it is\n via two axioms:\n\n * §2\n\n * §3\n\nOther theorems about naturals, such as §4,\nare proved by induction from these two basic theorems.": + "§0, com a notação §1, é o produto usual\n de números naturais. Internamente, ele é dado\n por dois axiomas:\n\n * §2\n\n * §3\n\nOutros teoremas sobre os naturais, como §4,\nsão provados por indução a partir desses dois teoremas básicos.", + "§0, with notation §1, is the usual\n exponentiation of natural numbers. Internally it is\n defined via two axioms:\n\n * §2\n\n * §3\n\nNote in particular that §4.": + "§0, com notação §1, é a exponenciação\n usual de números naturais. Internamente ela é\n definida por dois axiomas:\n\n * §2\n\n * §3\n\nNote em particular que §4.", + "§0, with notation §1, is\nthe usual sum of natural numbers. Internally it is defined\nvia the following two hypotheses:\n\n* §2\n\n* §3\n\nOther theorems about naturals, such as §4, are proved\nby induction using these two basic theorems.\"": + "§0, com a notação §1, é\na soma usual de números naturais. Internamente ela é definida\npelas duas hipóteses seguintes:\n\n* §2\n\n* §3\n\nOutros teoremas sobre os naturais, como §4, são provados\npor indução usando esses dois teoremas básicos.\"", + "§0 will do this.": "§0 dá conta disso.", + "§0 will change §1 into §2.": "§0 vai transformar §1 para §2.", + "§0 says that §1.\n\nNote that this is not quite true by definition: §2 is\ndefined to be §3 so it's §4, and to prove\nthat this is equal to §5 you need to use induction somewhere.": + "§0 diz que §1.\n\nRepare que isso não é bem verdade por definição: §2 é\ndefinido como §3, ou seja, é §4, e para provar\nque isso é igual a §5 você precisa usar indução em algum momento.", + "§0 says that §1.": "§0 diz que §1.", + "§0 practice.": "Praticando §0.", + "§0 is the theorem that §1.\nYou can prove it by induction on §2 or you can deduce it from §3.": + "§0 é o teorema de que §1.\nVocê pode prová-lo por indução em §2 ou pode o deduzir usando §3.", + "§0 is the theorem that §1\nTwo ways to do it spring to mind; I'll mention them when you've solved it.": + "§0 é o teorema de que §1\nDuas maneiras de fazer isso me vêm à cabeça; vou mencioná-las quando você resolver.", + "§0 is the theorem that §1": "§0 é o teorema de que §1", + "§0 is the statement that §1": "§0 é o enunciado de que §1", + "§0 is the proof §1.": "§0 é a prova de §1.", + "§0 is the proof that §1.\n\nNote: §2 is a §3 lemma.": + "§0 é a prova de que §1.\n\nObservação: §2 é um lema §3.", + "§0 is the proof that §1.\n\nIt could be deduced from §2 and §3, however this argument\nwould be circular because the proof of §4 uses §5.": + "§0 é a prova de que §1.\n\nIsso poderia ser deduzido de §2 e §3, porém esse argumento\nseria circular, porque a prova de §4 usa §5.", + "§0 is the proof that §1.\n\nIn Lean, §2 is *defined to mean* §3. Hence\n§4 is really a proof of §5.\nHere §6 is a generic false statement. This means that\nyou can §7 if §8 is a proof of §9.": + "§0 é a prova de que §1.\n\nEm Lean, §2 é *definido como* §3. Portanto\n§4 é na verdade uma prova de §5.\nAqui §6 é uma afirmação falsa genérica. Isso significa que\nvocê pode fazer §7 se §8 é uma prova de §9.", + "§0 is the proof that §1.": "§0 é a prova de que §1.", + "§0 is the proof that multiplication is commutative. More precisely,\n§1 is the proof that §2.": + "§0 é a prova de que a multiplicação é comutativa. Mais precisamente,\n§1 é a prova de que §2.", + "§0 is the proof of §1.\n\n§2 is a §3 lemma, because replacing §4 by §5\nis almost always what you want to do if you're simplifying an expression.": + "§0 é a prova de §1.\n\n§2 é um lema §3, porque substituir §4 por §5\né quase sempre o que você quer fazer ao simplificar uma expressão.", + "§0 is the proof of §1.": "§0 é a prova de §1.", + "§0 is the number after the number after §1.": + "§0 é o número depois do número depois de §1.", + "§0 is the natural numbers, just called \\\\\"numbers\\\\\" in this game. It's\ndefined via two rules:\n\n* §1 (zero is a number)\n* §2 (the successor of a number is a number)\n\n## Game Implementation\n\n*The game uses its own copy of the natural numbers, called §3 with notation §4.\nIt is distinct from the Lean natural numbers §5, which should hopefully\nnever leak into the natural number game.*": + "§0 são os números naturais, chamados apenas de \\\\\"números\\\\\" neste jogo. Eles são\ndefinidos por duas regras:\n\n* §1 (zero é um número)\n* §2 (o sucessor de um número é um número)\n\n## Implementação do jogo\n\n*O jogo usa sua própria cópia dos números naturais, chamada §3 com a notação §4.\nEla é distinta dos números naturais do Lean, §5, que, esperamos,\nnunca vazem para dentro do jogo dos números naturais.*", + "§0 is one of the two axioms\ndefining exponentiation in this game.": + "§0 é um dos dois axiomas\nque definem a exponenciação neste jogo.", + "§0 is one of the\ntwo axioms defining exponentiation in this game.": + "§0 é um dos\ndois axiomas que definem a exponenciação neste jogo.", + "§0 is just as fiddly to prove by induction; but there's a trick\nwhich avoids it. Can you spot it?": + "§0 é igualmente chato de provar por indução; mas existe um truque\nque evita isso. Consegue achá-lo?", + "§0 is good enough to solve this goal.": + "§0 já é o bastante para chegar no objetivo.", + "§0 is an ancient magic spell, believed to be the origin of the\nmodern word §1. The game won't complain - or notice - if you\nprove anything with §2.": + "§0 é um antigo feitiço mágico, tido como a origem da\npalavra moderna §1. O jogo não vai reclamar - nem perceber - se você\nprovar qualquer coisa com §2.", + "§0 is a proof that §1. But if your goal\nis §2 then §3 will not\nwork! Because the goal means §4 so there\nis no §5 term *directly* in the goal.\n\nUse associativity and commutativity to prove §6.\nYou don't need induction. §7 moves brackets around,\nand §8 moves variables around.\n\nRemember that you can do more targetted rewrites by\nadding explicit variables as inputs to theorems. For example §9\nwill only do rewrites of the form §10, and §11\nwill only do rewrites of the form §12.": + "§0 é uma prova de que §1. Mas se o seu objetivo\né §2 então §3 não vai\nfuncionar! Porque o objetivo significa §4, então não\nexiste nenhum termo §5 *diretamente* no objetivo.\n\nUse associatividade e comutatividade para provar §6.\nVocê não precisa de indução. §7 move os parênteses,\ne §8 move as variáveis.\n\nLembre que você pode fazer reescritas mais direcionadas\nadicionando variáveis explícitas como entradas dos teoremas. Por exemplo, §9\nsó vai fazer reescritas da forma §10, e §11\nsó vai fazer reescritas da forma §12.", + "§0 is a proof that §1.\n\nNote that when Lean says §2 it means §3.\n\nNote that §4 cannot be proved by \\\\\"pure thought\\\\\":\nfor example subtraction is not associative, as §5 is not\nequal to §6.": + "§0 é uma prova de que §1.\n\nNote que, quando Lean escreve §2, ele quer dizer §3.\n\nNote que §4 não pode ser provado por \\\\\"puro pensamento\\\\\":\npor exemplo, a subtração não é associativa, pois §5 não é\nigual a §6.", + "§0 is a proof that §1.\n\nIt's one way of saying that a divisor of a positive number\nhas to be at most that number.": + "§0 é uma prova de que §1.\n\nÉ um jeito de dizer que um divisor de um número positivo\ntem que ser no máximo esse número.", + "§0 is a proof that §1.\n\n## Summary\n\n§2 is really a function, which\neats a number, and returns a proof of a theorem\nabout that number. For example §3 is\na proof that §4.\n\nThe §5 tactic will accept §6\nand will try to figure out which number you omitted\nto input.\n\n## Details\n\nA mathematician sometimes thinks of §7\nas \\\\\"one thing\\\\\", namely a proof of §8.\nThis is just another way of saying that it's a function which\ncan eat any number n and will return a proof that §9.": + "§0 é uma prova de que §1.\n\n## Resumo\n\n§2 é na verdade uma função, que\ncome um número e devolve uma prova de um teorema\nsobre esse número. Por exemplo, §3 é\numa prova de que §4.\n\nA tática §5 aceita §6\ne vai tentar descobrir qual número você deixou\nde fornecer.\n\n## Detalhes\n\nMatemáticos às vezes pensam em §7\ncomo \\\\\"uma coisa só\\\\\", a saber, uma prova de que §8.\nIsso é apenas outra maneira de dizer que é uma função que\npode comer qualquer número n e devolver uma prova de que §9.", + "§0 is a proof that §1.": "§0 é uma prova de que §1.", + "§0 is a proof that §1 or §2.": "§0 é uma prova de que §1 ou §2.", + "§0 is a proof that §1\n\nIn Lean, §2 means §3, so this result gets displayed\nas §4.": + "§0 é a prova de que §1\n\nEm Lean, §2 significa §3, então esse resultado é exibido\ncomo §4.", + "§0 is a proof that §1": "§0 é a prova de que §1", + "§0 is a proof that if §1 then §2.": "§0 é uma prova de que, se §1, então §2.", + "§0 is a proof that if §1 then §2 or §3.": + "§0 é a prova de que se §1 então §2 ou §3.", + "§0 is a proof that if §1 then §2 or §3 or §4.": + "§0 é a prova de que se §1 então §2 ou §3 ou §4.", + "§0 is a proof that if §1 and §2 then §3.\nMore precisely, it is a proof that §4. In words,\nIf §5 then (pause) if §6 then §7.\n\n## A note on associativity\n\nIn Lean, §8 means §9, because §10 is left associative. However\n§11 is right associative. This means that §12 in Lean means\nexactly that §13 is transitive. This is different to how mathematicians use\n§14; for them, this usually means that §15\nand §16.": + "§0 é uma prova de que se §1 e §2, então §3.\nMais precisamente, é a prova de que §4. Em palavras,\nse §5 então (pausa) se §6 então §7.\n\n## Uma observação sobre associatividade\n\nEm Lean, §8 significa §9, porque §10 é associativo à esquerda. Já\n§11 é associativo à direita. Isso significa que §12 em Lean quer dizer\nexatamente que §13 é transitiva. Isso é diferente de como os matemáticos usam\n§14; para eles, isso normalmente significa que §15\ne §16.", + "§0 is a proof that if §1 and §2 then §3.": + "§0 é a prova de que se §1 e §2 então §3.", + "§0 is a proof of §1.\"": "§0 é uma prova de §1.\"", + "§0 is a proof of §1.\n\nThe reason for the name is that this lemma is \"reflexivity of §2\"": + "§0 é uma prova de §1.\n\nO motivo do nome é que este lema é a \"reflexividade de §2\"", + "§0 is a proof of §1.": "§0 é uma prova de §1.", + "§0 is a proof of §1 so that was what got rewritten.\nYou can now change §2 to §3 with §4 or §5. You\ncan usually stick to §6 unless you need real precision.": + "§0 é uma prova de §1, então foi isso que foi reescrito.\nAgora você pode mudar §2 para §3 com §4 ou §5. Em geral você\npode ficar com §6, a menos que precise de precisão de verdade.", + "§0 is a proof of the implication §1.": "§0 é uma prova da implicação §1.", + "§0 is a proof\nthat §1. Note that in Lean §2 prints\nas §3, because the notation for addition is defined to be left\nassociative.": + "§0 é uma prova\nde que §1. Note que no Lean §2 aparece\ncomo §3, porque a notação para adição é definida como associativa\nà esquerda.", + "§0 is I think quicker than §1.": "§0 é, eu acho, mais rápido do que §1.", + "§0 is *notation* for §1. This \"backwards E\"\nmeans \"there exists\". So §2 means that there exists\na number §3 such that §4. This definition works\nbecause there are no negative numbers in this game.\n\nTo *prove* an \"exists\" statement, use the §5 tactic.\nLet's see an example.": + "§0 é *notação* para §1. Esse \"E ao contrário\"\nsignifica \"existe\". Então §2 quer dizer que existe\num número §3 tal que §4. Essa definição funciona\nporque não há números negativos neste jogo.\n\nPara *provar* um enunciado de existência, use a tática §5.\nVamos ver um exemplo.", + "§0 is *notation* for §1.\n\nThe reason this is mathematically\nvalid is that if §2 is a true-false statement then §3\nis the logical opposite of §4. Indeed §5 is false,\nand §6 is true!\n\nThe upshot of this is that you can treat §7 in exactly\nthe same way as you treat any implication §8. For example,\nif your *goal* is of the form §9 then you can make progress\nwith §10, and if you have a hypothesis §11 of the\nform §12 then you can §13 if §14 is a proof\nof §15.": + "§0 é uma *notação* para §1.\n\nA razão pela qual isso é matematicamente\nválido é que, se §2 é uma afirmação verdadeiro-falso, então §3\né o oposto lógico de §4. De fato, §5 é falso,\ne §6 é verdadeiro!\n\nA consequência disso é que você pode tratar §7 exatamente\nda mesma forma que trata qualquer implicação §8. Por exemplo,\nse seu *objetivo* é da forma §9, então você pode progredir\ncom §10, e se você tem uma hipótese §11 da\nforma §12, então você pode fazer §13 se §14 for uma prova\nde §15.", + "§0 is *notation* for §1.\n\nBecause this game doesn't have negative numbers, this definition\nis mathematically valid.\n\nThis means that if you have a goal of the form §2 you can\nmake progress with the §3 tactic, and if you have a hypothesis\n§4, you can make progress with §5.": + "§0 é *notação* para §1.\n\nComo este jogo não tem números negativos, essa definição\né matematicamente válida.\n\nIsso significa que, se você tem um objetivo da forma §2, você pode\navançar com a tática §3, e se você tem uma hipótese\n§4, você pode avançar com §5.", + "§0": "§0", + "zero_pow_zero": "zero_pow_zero", + "zero_pow_succ": "zero_pow_succ", + "zero_ne_succ": "zero_ne_succ", + "zero_mul": "zero_mul", + "zero_add": "zero_add", + "x ≤ y or y ≤ x": "x ≤ y ou y ≤ x", + "x ≤ y and y ≤ z implies x ≤ z": "x ≤ y e y ≤ z implica x ≤ z", + "x ≤ y and y ≤ x implies x = y": "x ≤ y e y ≤ x implica x = y", + "x ≤ succ x": "x ≤ succ x", + "x ≤ 1": "x ≤ 1", + "x ≤ 0 → x = 0": "x ≤ 0 → x = 0", + "two_mul": "two_mul", + "try rewriting §0.": "tente reescrever §0.", + "the simplest approach": "a abordagem mais simples", + "the rw tactic": "a tática rw", + "succ_mul": "succ_mul", + "succ_inj : the successor function is injective": + "succ_inj : a função sucessor é injetiva", + "succ_add": "succ_add", + "succ x ≤ succ y → x ≤ y": "succ x ≤ succ y → x ≤ y", + "rewriting backwards": "reescrevendo de trás pra frente", + "pred": "pred", + "pow_two": "pow_two", + "pow_pow": "pow_pow", + "pow_one": "pow_one", + "pow_add": "pow_add", + "one_pow": "one_pow", + "one_mul": "one_mul", + "one_le_of_ne_zero": "one_le_of_ne_zero", + "mul_right_eq_self": "mul_right_eq_self", + "mul_right_eq_one": "mul_right_eq_one", + "mul_pow": "mul_pow", + "mul_one": "mul_one", + "mul_ne_zero": "mul_ne_zero", + "mul_left_ne_zero": "mul_left_ne_zero", + "mul_left_cancel": "mul_left_cancel", + "mul_le_mul_right": "mul_le_mul_right", + "mul_eq_zero": "mul_eq_zero", + "mul_comm": "mul_comm", + "mul_assoc": "mul_assoc", + "mul_add": "mul_add", + "making life simple": "simplificando a vida", + "making life easier": "facilitando a vida", + "level completed! 🎉": "nível completado! 🎉", + "level completed with warnings… 🎭": "nível completado com avisos… 🎭", + "le_two": "le_two", + "le_mul_right": "le_mul_right", + "is_zero": "is_zero", + "intro practice": "praticando intro", + "intro": "intro", + "intermediate goal solved! 🎉": "objetivo intermediário resolvido! 🎉", + "eq_succ_of_ne_zero": "eq_succ_of_ne_zero", + "decide again": "decide de novo", + "decide": "decide", + "add_succ": "add_succ", + "add_sq": "add_sq", + "add_right_eq_zero": "add_right_eq_zero", + "add_right_eq_self": "add_right_eq_self", + "add_right_comm": "add_right_comm", + "add_right_cancel": "add_right_cancel", + "add_mul": "add_mul", + "add_left_eq_zero": "add_left_eq_zero", + "add_left_eq_self": "add_left_eq_self", + "add_left_comm": "add_left_comm", + "add_left_cancel": "add_left_cancel", + "add_comm (level boss)": "add_comm (chefão)", + "add_assoc (associativity of addition)": + "add_assoc (associatividade da adição)", + "[final boss music]": "[música de chefão final]", + "[dramatic music]. Now are you ready to face the first boss of the game?": + "[música dramática]. Você está pronto para encarar o primeiro chefão do jogo?", + "[boss battle music]\n\nLook in your inventory to see the proofs you have available.\nThese should be enough.": + "[música de batalha contra o chefão]\n\nOlhe no seu inventário para ver as provas que você tem disponíveis.\nElas devem ser suficientes.", + "You've now seen all the tactics you need to beat the final boss of the game.\nYou can begin the journey towards this boss by entering Multiplication World.\n\nOr you can go off the beaten track and learn some new tactics in Implication\nWorld. These tactics let you prove more facts about addition, such as\nhow to deduce §0 from §1.\n\nClick \"Leave World\" and make your choice.": + "Você já viu todas as táticas de que precisa para derrotar o chefão final do jogo.\nVocê pode começar a jornada até esse chefão entrando no Mundo da Multiplicação.\n\nOu pode sair do caminho comum e aprender algumas táticas novas no Mundo da\nImplicação. Essas táticas permitem provar mais fatos sobre a adição, como\ndeduzir §0 a partir de §1.\n\nClique em \"Leave World\" e faça a sua escolha.", + "You want to use §0, which you already\nproved, but you'll have to start with §1 your hypothesis.": + "Você quer usar §0, que você já\nprovou, mas vai ter que começar com §1 na sua hipótese.", + "You still don't know which way to go, so do §0.": + "Você ainda não sabe para que lado ir, então faça §0.", + "You now know enough tactics to prove §0! Let's begin the journey.": + "Agora você já conhece táticas suficientes para provar §0! Vamos começar a jornada.", + "You might want to think about whether induction\non §0 or §1 is the best idea.": + "Talvez você queira pensar se indução\nem §0 ou em §1 é a melhor ideia.", + "You can use §0 to rewrite at §1 instead\nof at the goal.": + "Você pode usar §0 para reescrever em §1 em vez\nde no objetivo.", + "You can start a proof by induction on §0 by typing:\n§1.": + "Você pode começar uma prova por indução em §0 digitando:\n§1.", + "You can read more about the §0 tactic by clicking\non it in the top right.": + "Você pode ler mais sobre a tática §0 clicando\nnela no canto superior direito.", + "You can put a §0 in front of any theorem provided to §1 to rewrite\nthe other way around. Look at the docs for §2 for an explanation. Type §3 with §4.": + "Você pode colocar um §0 na frente de qualquer teorema passado para §1 para reescrever\nno sentido contrário. Veja a documentação de §2 para uma explicação. Digite §3 com §4.", + "You can prove §0 in at least three ways.\nEither by induction, or by using §1, or\nby using commutativity. Which do you think is quickest?": + "Você pode provar §0 de pelo menos três jeitos.\nOu por indução, ou usando §1, ou\nusando comutatividade. Qual você acha que é o mais rápido?", + "You can probably take it from here.": + "Você provavelmente consegue seguir daqui.", + "You can now §0": "Agora você pode §0", + "You can now finish with §0.": "Agora você pode terminar com §0.", + "You can make your own tactics in Lean.\nThis code here\n§0\nwas used to create a new tactic §1, which runs\n§2.\nTry running §3 to solve this level!": + "Você pode criar suas próprias táticas em Lean.\nEste código aqui\n§0\nfoi usado para criar uma nova tática §1, que executa\n§2.\nTente executar §3 para resolver este nível!", + "You can just mimic the previous proof to do this one -- or you can figure out a way\nof using it.": + "Você pode simplesmente imitar a prova anterior para fazer esta -- ou pode descobrir um jeito\nde usá-la.", + "You can do induction on any of the three variables. Some choices\nare harder to push through than others. Can you do the inductive step in\n5 rewrites only?": + "Você pode fazer indução em qualquer uma das três variáveis. Algumas escolhas\nsão mais difíceis de levar até o fim do que outras. Você consegue fazer o passo indutivo em\napenas 5 reescritas?", + "Why did we not just define §0 to be §1? Because we have not\neven *defined* addition yet! We'll do that in the next level.": + "Por que não definimos logo §0 como §1? Porque ainda nem\n*definimos* a adição! Vamos fazer isso no próximo nível.", + "What do you think of this two-liner:\n§0\n\n§1 doesn't just take hypotheses, it will eat any proof which exists\nin the system.": + "O que você acha destas duas linhas:\n§0\n\n§1 não aceita apenas hipóteses, ele engole qualquer prova que exista\nno sistema.", + "Well done! You now have enough tools to tackle the main boss of this level.": + "Muito bem! Agora você tem ferramentas suficientes para enfrentar o chefão principal deste nível.", + "Well done!": "Muito bem!", + "Welcome to tutorial world! In this world we learn the basics\nof proving theorems. The boss level of this world\nis the theorem §0.\n\nYou prove theorems by solving puzzles using tools called *tactics*.\nThe aim is to prove the theorem by applying tactics\nin the right order.\n\nLet's learn some basic tactics. Click on \"Start\" below\nto begin your quest.": + "Bem-vindo ao mundo do tutorial! Neste mundo aprendemos o básico\nde como provar teoremas. O chefão deste mundo\né o teorema §0.\n\nVocê prova teoremas resolvendo quebra-cabeças com ferramentas chamadas *táticas*.\nO objetivo é provar o teorema aplicando táticas\nna ordem certa.\n\nVamos aprender algumas táticas básicas. Clique em \"Começar\" abaixo\npara começar sua jornada.", + "Welcome to Addition World! In this world we'll learn the §0 tactic.\nThis will enable us to defeat the boss level of this world, namely §1.\n\nThe tactics §2, §3 and §4 are the only tactics you'll need to\nbeat all the levels in Addition World, Multiplication World, and Power World.\nPower World contains the final boss of the game.\n\nThere are plenty more tactics in this game, but you'll only need to know them if you\nwant to explore the game further (for example if you decide to 100%\nthe game).": + "Bem-vindo ao Mundo da Adição! Neste mundo vamos aprender a tática §0.\nIsso vai nos permitir derrotar o chefão deste mundo, a saber, §1.\n\nAs táticas §2, §3 e §4 são as únicas de que você vai precisar para\nvencer todos os níveis do Mundo da Adição, do Mundo da Multiplicação e do Mundo da Potência.\nO Mundo da Potência contém o chefão final do jogo.\n\nHá muitas outras táticas neste jogo, mas você só vai precisar conhecê-las se\nquiser explorar o jogo mais a fundo (por exemplo, se você decidir zerar\no jogo em 100%).", + "We've seen §0, the proof that if §1 then §2.\nNow we'll prove that if §3 then §4 or §5.": + "Já vimos §0, a prova de que se §1 então §2.\nAgora vamos provar que se §3 então §4 ou §5.", + "We've proved that §0; in Implication World we'll learn\nhow to prove §1.\n\nIn Addition World we proved *equalities* like §2.\nIn this second tutorial world we'll learn some new tactics,\nenabling us to prove *implications*\nlike §3\n\nWe'll also learn two new fundamental facts about\nnatural numbers, which Peano introduced as axioms.\n\nClick on \"Start\" to proceed.": + "Provamos que §0; no Mundo da Implicação vamos aprender\ncomo provar §1.\n\nNo Mundo da Adição provamos *igualdades* como §2.\nNeste segundo mundo tutorial vamos aprender algumas táticas novas,\nque nos permitirão provar *implicações*\ncomo §3\n\nTambém vamos aprender dois novos fatos fundamentais sobre\nos números naturais, que Peano introduziu como axiomas.\n\nClique em \"Começar\" para continuar.", + "We've proved that §0 implies §1. The last two levels\nin this world will prove which numbers are §2 and §3.\nThis lemma will be helpful for them.": + "Provamos que §0 implica §1. Os dois últimos níveis\ndeste mundo vão provar quais números são §2 e §3.\nEste lema será útil para eles.", + "We've just seen that §0, but if §1\nis a successor, then §2. We prove that here.": + "Acabamos de ver que §0, mas se §1\né um sucessor, então §2. Vamos provar isso aqui.", + "We've been adding up two numbers; in this level we will add up three.\n\n What does §0 *mean*? It could either mean §1, or it\n could mean §2. In Lean, §3 means §4.\n\n But why do we care which one it means; §5 and §6 are *equal*!\n\n That's true, but we didn't prove it yet. Let's prove it now by induction.": + "Estivemos somando dois números; neste nível vamos somar três.\n\n O que §0 *significa*? Pode significar §1, ou pode\n significar §2. Em Lean, §3 significa §4.\n\n Mas por que nos importamos com qual dos dois significa; §5 e §6 são *iguais*!\n\n É verdade, mas ainda não provamos isso. Vamos provar agora por indução.", + "We're going to change that §0 into §1. Start by changing it into\n§2 by executing §3.": + "Vamos trocar esse §0 por §1. Comece transformando-o em\n§2 executando §3.", + "We'll need this lemma to prove that two is prime!\n\nYou'll need to know that §0 is right associative. This means that\n§1 actually means §2.\nThis affects how §3 and §4 work.": + "Vamos precisar deste lema para provar que dois é primo!\n\nVocê precisa saber que §0 é associativo à direita. Isso significa que\n§1 na verdade quer dizer §2.\nIsso afeta como §3 e §4 funcionam.", + "We'd like to prove §0 but right now\nwe can't even *state* it\nbecause we haven't yet defined addition.\n\n## Defining addition.\n\nHow are we going to add §1 to an arbitrary number §2? Well,\nthere are only two ways to make numbers in this game: §3\nand successors. So to define §4 we will need\nto know what §5 is and what §6 is.\nLet's start with adding §7.\n\n### Adding 0\n\nTo make addition agree with our intuition, we should *define* §8\nto be §9. More generally, we should define §10 to be §11 for\nany number §12. The name of this proof in Lean is §13.\nFor example §14 is a proof of §15,\n§16 is a proof of §17, and §18 is a proof\nof §19.\n\nWe write §20, so §21.": + "Gostaríamos de provar §0 mas neste momento\nnem sequer conseguimos *enunciar* isso\nporque ainda não definimos a adição.\n\n## Definindo a adição.\n\nComo vamos somar §1 a um número arbitrário §2? Bem,\nsó existem duas maneiras de construir números neste jogo: §3\ne sucessores. Então, para definir §4 vamos precisar\nsaber o que é §5 e o que é §6.\nVamos começar somando §7.\n\n### Somando 0\n\nPara que a adição concorde com nossa intuição, devemos *definir* §8\ncomo §9. De modo mais geral, devemos definir §10 como §11 para\nqualquer número §12. O nome dessa prova em Lean é §13.\nPor exemplo, §14 é uma prova de §15,\n§16 é uma prova de §17, e §18 é uma prova\nde §19.\n\nEscrevemos §20, ou seja, `prova : enunciado`.", + "We want to use §0, but we need a hypothesis §1\nwhich we don't have. Yet. Execute §2 (you can type §3 with §4).\nYou'll be asked to\nprove it, and then you'll have a new hypothesis which you can apply\n§5 to.": + "Queremos usar §0, mas precisamos de uma hipótese §1\nque não temos. Ainda. Execute §2 (você pode digitar §3 com §4).\nVocê terá que\nprová-la, e então terá uma nova hipótese na qual poderá aplicar\n§5.", + "We want to reduce this to a hypothesis §0 and a goal §1,\nwhich is logically equivalent but much easier to prove. Remember that §2\nis notation for §3. Click on §4 if you need hints.": + "Queremos reduzir isso a uma hipótese §0 e um objetivo §1,\nque é logicamente equivalente mas muito mais fácil de provar. Lembre que §2\né notação para §3. Clique em `Mostrar mais ajuda!` se precisar de dicas.", + "We still can't prove §0 because we have not talked about the\ndefinition of §1. In Lean, §2 is *notation* for §3.\nHere §4 is a generic false proposition, and §5 is Lean's notation\nfor \"implies\". In logic we learn\nthat §6 is false, but §7 is true. Hence\n§8 is the logical opposite of §9.\n\nEven though §10 does not look like an implication,\nyou should treat it as an implication. The next two levels will show you how.\n\n§11 is a goal which you cannot deduce from a consistent set of assumptions!\nSo if your goal is §12 then you had better hope that your hypotheses\nare contradictory, which they are in this level.": + "Ainda não podemos provar §0 porque não falamos sobre a\ndefinição de §1. Em Lean, §2 é *notação* para §3.\nAqui §4 é uma proposição falsa genérica, e §5 é a notação de Lean\npara \"implica\". Em lógica aprendemos\nque §6 é falso, mas §7 é verdadeiro. Logo,\n§8 é o oposto lógico de §9.\n\nMesmo que §10 não pareça uma implicação,\nvocê deve tratá-lo como uma implicação. Os dois próximos níveis vão te mostrar como.\n\n§11 é um objetivo que você não consegue deduzir de um conjunto consistente de hipóteses!\nEntão, se seu objetivo é §12, é melhor torcer para que suas hipóteses\nsejam contraditórias, o que é o caso neste nível.", + "We now start work on an algorithm to do addition more efficiently. Recall that\nwe defined addition by recursion, saying what it did on §0 and successors.\nIt is an axiom of Lean that recursion is a valid\nway to define functions from types such as the naturals.\n\nLet's define a new function §1 from the naturals to the naturals, which\nattempts to subtract 1 from the input. The definition is this:\n\n§2\n\nWe cannot subtract one from 0, so we just return a junk value. As well as this\ndefinition, we also create a new lemma §3, which says that §4.\nLet's use this lemma to prove §5, the theorem which\nPeano assumed as an axiom and which we have already used extensively without justification.": + "Agora começamos a trabalhar em um algoritmo para fazer adição de forma mais eficiente. Lembre-se de que\ndefinimos a adição por recursão, dizendo o que ela faz em §0 e em sucessores.\nÉ um axioma de Lean que a recursão é uma maneira válida\nde definir funções a partir de tipos como os naturais.\n\nVamos definir uma nova função §1 dos naturais nos naturais, que\ntenta subtrair 1 da entrada. A definição é esta:\n\n§2\n\nNão podemos subtrair um de 0, então simplesmente devolvemos um valor lixo. Além dessa\ndefinição, também criamos um novo lema §3, que diz que §4.\nVamos usar esse lema para provar §5, o teorema que\nPeano presumiu como axioma e que já usamos bastante sem justificativa.", + "We now have enough to state a mathematically accurate, but slightly\nclunky, version of Fermat's Last Theorem.\n\nFermat's Last Theorem states that if §0 and §1 then §2.\nIf you didn't do inequality world yet then we can't talk about §3,\nso we have to resort to the hack of using §4 for §5,\nwhich guarantees it's big enough. Similarly instead of §6 we\nuse §7.\n\nThis level looks superficially like other levels we have seen,\nbut the shortest solution known to humans would translate into\nmany millions of lines of Lean code. The author of this game,\nKevin Buzzard, is working on translating the proof by Wiles\nand Taylor into Lean, although this task will take many years.\n\n## CONGRATULATIONS!\n\nYou've finished the main quest of the natural number game!\nIf you would like to learn more about how to use Lean to\nprove theorems in mathematics, then take a look\nat [Mathematics In Lean](https://leanprover-community.github.io/mathematics_in_lean/),\nan interactive textbook which you can read in your browser,\nand which explains how to work with many more mathematical concepts in Lean.": + "Agora já temos o suficiente para enunciar uma versão matematicamente correta, mas\num pouco desajeitada, do Último Teorema de Fermat.\n\nO Último Teorema de Fermat diz que se §0 e §1 então §2.\nSe você ainda não fez o mundo das desigualdades, não podemos falar de §3,\nentão temos que recorrer à gambiarra de usar §4 no lugar de §5,\no que garante que ele é grande o bastante. Da mesma forma, em vez de §6\nusamos §7.\n\nEste nível parece, superficialmente, com outros níveis que já vimos,\nmas a solução mais curta conhecida pela humanidade se traduziria em\nmuitos milhões de linhas de código Lean. O autor deste jogo,\nKevin Buzzard, está trabalhando em traduzir a prova de Wiles\ne Taylor para Lean, embora essa tarefa vá levar muitos anos.\n\n## PARABÉNS!\n\nVocê terminou a missão principal do jogo dos números naturais!\nSe você quiser aprender mais sobre como usar Lean para\nprovar teoremas em matemática, dê uma olhada\nem [Mathematics In Lean](https://leanprover-community.github.io/mathematics_in_lean/),\num livro-texto interativo que você pode ler no navegador,\ne que explica como trabalhar com muitos outros conceitos matemáticos em Lean.", + "We now have enough to prove that multiplication is associative,\nthe boss level of multiplication world. Good luck!": + "Agora já temos o suficiente para provar que a multiplicação é associativa,\no chefão do Mundo da Multiplicação. Boa sorte!", + "We know §0 is a proof of §1 -- but what\nif we have a hypothesis §2? It's the wrong way around!\n\nThe §3 tactic changes a goal §4 to §5, and a goal §6\nto §7. And §8\ndoes the same for a hypothesis §9. We've proved §10 and called\nthe proof §11; now try proving §12.": + "Sabemos que §0 é uma prova de §1 -- mas e\nse tivermos uma hipótese §2? Está ao contrário!\n\nA tática §3 muda um objetivo §4 para §5, e um objetivo §6\npara §7. E §8\nfaz o mesmo para uma hipótese §9. Já provamos §10 e chamamos\na prova de §11; agora tente provar §12.", + "We have seen how to §0 theorems and assumptions\nof the form §1. But what if our *goal* is of the form §2?\nTo prove this goal, we need to know how to say \"let's assume §3 and deduce §4\"\nin Lean. We do this with the §5 tactic.": + "Já vimos como usar §0 em teoremas e hipóteses\nda forma §1. Mas e se o nosso *objetivo* for da forma §2?\nPara provar esse objetivo, precisamos saber como dizer \"vamos supor §3 e deduzir §4\"\nem Lean. Fazemos isso com a tática §5.", + "We gave a pretty unsatisfactory proof of §0 earlier on; now give a nicer one.": + "Demos uma prova bem insatisfatória de §0 lá atrás; agora dê uma mais bonita.", + "We don't know whether to go left or right yet. So start with §0.": + "Ainda não sabemos se vamos para a esquerda ou para a direita. Então comece com §0.", + "We define a function §0 thus:\n\n§1\n\nWe also create two lemmas, §2 and §3, saying that §4\nand §5. Let's use these lemmas to prove §6, Peano's\nLast Axiom. Actually, we have been using §7 before, but it's handy to have\nthis opposite version too, which can be proved in the same way. Note: you can\ncheat here by using §8 but the point of this world is to show\nyou how to *prove* results like that.\n\nIf you can turn your goal into §9, then the §10 tactic will solve it.": + "Definimos uma função §0 assim:\n\n§1\n\nTambém criamos dois lemas, §2 e §3, dizendo que §4\ne §5. Vamos usar esses lemas para provar §6, o Último\nAxioma de Peano. Na verdade, já usamos §7 antes, mas é útil ter\nesta versão oposta também, que pode ser provada da mesma forma. Nota: você pode\ntrapacear aqui usando §8, mas a ideia deste mundo é mostrar\ncomo *provar* resultados desse tipo.\n\nSe você conseguir transformar seu objetivo em §9, então a tática §10 vai resolvê-lo.", + "Very well done.\n\nA passing mathematician remarks that with you've just proved that §0 is totally\nordered.\n\nThe final few levels in this world are much easier.": + "Muito bem!\n\nUm matemático que passava por aqui observa que você acabou de provar que §0 é totalmente\nordenado.\n\nOs últimos níveis deste mundo são bem mais fáceis.", + "Use §0.": "Use §0.", + "Use §0 and remember that §1 will solve a goal\nif there are hypotheses §2 and §3.": + "Use §0 e lembre que §1 resolve um objetivo\nse houver hipóteses §2 e §3.", + "Use the previous lemma with §0.": "Use o lema anterior com §0.", + "Tutorial World": "Mundo Tutorial", + "Try §0.": "Tente §0.", + "Try §0 to change §1 into §2.": "Tente §0 para transformar §1 em §2.", + "Totality of §0 is the boss level of this world, and it's coming up next. It says that\nif §1 and §2 are naturals then either §3 or §4.\nBut we haven't talked about §5 at all. Here's a run-through.\n\n1) The notation for \"or\" is §6. You won't need to type it, but you can\ntype it with §7.\n\n2) If you have an \"or\" statement in the *goal*, then two tactics make\nprogress: §8 and §9. But don't choose a direction unless your\nhypotheses guarantee that it's the correct one.\n\n3) If you have an \"or\" statement as a *hypothesis* §10, then\n§11 will create two goals, one where you went left,\nand the other where you went right.": + "A totalidade de §0 é o chefão deste mundo, e vem a seguir. Ela diz que,\nse §1 e §2 são naturais, então §3 ou §4.\nMas não falamos nada sobre §5 até agora. Aqui vai uma visão geral.\n\n1) A notação para \"ou\" é §6. Você não vai precisar digitá-la, mas pode\ndigitá-la com §7.\n\n2) Se você tem uma afirmação com \"ou\" no *objetivo*, então duas táticas fazem\nprogresso: §8 e §9. Mas não escolha uma direção a menos que suas\nhipóteses garantam que ela é a correta.\n\n3) Se você tem uma afirmação com \"ou\" como *hipótese* §10, então\n§11 vai criar dois objetivos, um em que você foi para a esquerda,\ne outro em que você foi para a direita.", + "To solve this level, you need to §0 a number §1 such that §2.": + "Para resolver este nível, você precisa usar §0 com um número §1 tal que §2.", + "Those of you interested in speedrunning the game may want to know\nthat §0 will do both rewrites at once.": + "Quem tiver interesse em fazer speedrun do jogo talvez queira saber\nque §0 faz as duas reescritas de uma vez só.", + "This world introduces exponentiation. If you want to define §0\nthen, as always, you will need to know what §1 is, and\nwhat §2 is, given only §3.\n\nYou can probably guess the names of the general theorems:\n\n * §4\n * §5\n\nUsing only these, can you get past the final boss level?\n\nThe levels in this world were designed by Sian Carey, a UROP student\nat Imperial College London, funded by a Mary Lister McCammon Fellowship\nin the summer of 2019. Thanks to Sian and also thanks to Imperial\nCollege for funding her.": + "Este mundo apresenta a exponenciação. Se você quiser definir §0\nentão, como sempre, vai precisar saber o que é §1, e\no que é §2, dado apenas §3.\n\nVocê provavelmente consegue adivinhar os nomes dos teoremas gerais:\n\n * §4\n * §5\n\nUsando apenas esses, você consegue passar do chefão final?\n\nOs níveis deste mundo foram criados por Sian Carey, estudante de UROP\nno Imperial College London, financiada por uma Mary Lister McCammon Fellowship\nno verão de 2019. Obrigado à Sian e também ao Imperial College por\nfinanciá-la.", + "This time, use the §0 tactic.": "Desta vez, use a tática §0.", + "This level proves §0, the multiplicative analogue of Advanced Addition\nWorld's §1. The strategy is to prove that §2 and then use the\nlemma §3 from §4 world.\n\nWe'll prove it using a new and very useful tactic called §5.": + "Este nível prova §0, o análogo multiplicativo do §1 do Mundo da\nAdição Avançada. A estratégia é provar que §2 e então usar o\nlema §3 do mundo §4.\n\nVamos prová-lo usando uma nova e muito útil tática chamada §5.", + "This level proves that if §0 then §1 or §2. It is\nlogically equivalent to the last level, so there is a very short proof.": + "Este nível prova que se §0 então §1 ou §2. Isso é\nlogicamente equivalente ao nível anterior, então há uma prova bem curta.", + "This level proves that if §0 and §1 then §2. One strategy\nis to write both §3 and §4 as §5 of something, deduce that §6 is\nalso §7 of something, and then §8.": + "Este nível prova que se §0 e §1 então §2. Uma estratégia\né escrever tanto §3 quanto §4 como §5 de alguma coisa, deduzir que §6 também\né §7 de alguma coisa, e então §8.", + "This level is more important than you think; it plays\na useful role when battling a big boss later on.": + "Este nível é mais importante do que você pensa; ele tem\num papel útil na batalha contra um grande chefão mais adiante.", + "This level asks you to prove *antisymmetry* of §0.\nIn other words, if §1 and §2 then §3.\nIt's the trickiest one so far. Good luck!": + "Este nível pede que você prove a *antissimetria* de §0.\nEm outras palavras, se §1 e §2 então §3.\nÉ o mais complicado até agora. Boa sorte!", + "This lemma would have been easy if we had known that §0. That theorem\n is called §1 and it is *true*, but unfortunately its proof *uses* both\n §2 and §3!\n\n Let's continue on our journey to §4, the proof of §5.": + "Este lema teria sido fácil se soubéssemos que §0. Esse teorema\n se chama §1 e é *verdadeiro*, mas infelizmente sua prova *usa* tanto\n §2 quanto §3!\n\n Vamos continuar nossa jornada rumo a §4, a prova de que §5.", + "This is I think the toughest level yet. Tips: if §0 is a number\nthen §1 will split into cases §2 and §3.\nAnd don't go left or right until your hypotheses guarantee that\nyou can prove the resulting goal!\n\nI've left hidden hints; if you need them, retry from the beginning\nand click on \"Show more help!\"": + "Este é, eu acho, o nível mais difícil até agora. Dicas: se §0 é um número,\nentão §1 vai dividir em dois casos, §2 e §3.\nE não vá usando táticas até que suas hipóteses garantam que\nvocê consegue provar o objetivo resultante!\n\nDeixei dicas escondidas; se você precisar delas, recomece do início\ne clique em \"Mostrar mais ajuda!\"", + "The §0 tactic.": "A tática §0.", + "The §0 tactic": "A tática §0", + "The way to start this proof is §0.": "O jeito de começar essa prova é §0.", + "The rfl tactic": "A tática rfl", + "The reason §0 is because §1.\nSo you should start this proof with §2.": + "A razão de §0 é que §1.\nEntão você deve começar esta prova com §2.", + "The previous lemma can be used to prove this one.": + "O lema anterior pode ser usado para provar este.", + "The next result we'll need in §0 World is that if §1 then §2 and §3.\nLet's prove one of these facts in this level, and the other in the next.\n\n## A new tactic: §4\n\nThe §5 tactic will split an object or hypothesis up into the possible ways\nthat it could have been created.\n\nFor example, sometimes you want to deal with the two cases §6 and §7 separately,\nbut don't need the inductive hypothesis §8 that comes with §9.\nIn this situation you can use §10 instead. There are two ways to make\na number: it's either zero or a successor. So you will end up with two goals, one\nwith §11 and one with §12.\n\nAnother example: if you have a hypothesis §13 then you are done, because a false statement implies\nany statement. Here §14 will close the goal, because there are *no* ways to\nmake a proof of §15! So you will end up with no goals, meaning you have proved everything.": + "O próximo resultado de que vamos precisar no Mundo do §0 é que, se §1, então §2 e §3.\nVamos provar um desses fatos neste nível, e o outro no próximo.\n\n## Uma nova tática: §4\n\nA tática §5 divide um objeto ou uma hipótese nas possíveis maneiras\npelas quais ele poderia ter sido criado.\n\nPor exemplo, às vezes você quer tratar os dois casos §6 e §7 separadamente,\nmas não precisa da hipótese indutiva §8 que vem junto com §9.\nNessa situação você pode usar §10 no lugar. Há duas maneiras de construir\num número: ele é zero ou é um sucessor. Então você vai acabar com dois objetivos, um\ncom §11 e outro com §12.\n\nOutro exemplo: se você tem uma hipótese §13, então acabou, porque uma afirmação falsa implica\nqualquer afirmação. Aqui §14 fecha o objetivo, porque *não há* maneira de\nconstruir uma prova de §15! Então você vai acabar sem nenhum objetivo, o que significa que provou tudo.", + "The music gets ever more dramatic, as we explore\nthe interplay between exponentiation and multiplication.\n\nIf you're having trouble exchanging the right §0\nbecause §1 swaps the wrong multiplication,\nthen read the documentation of §2 for tips on how to fix this.": + "A música fica cada vez mais dramática, enquanto exploramos\na interação entre exponenciação e multiplicação.\n\nSe você estiver tendo dificuldade para trocar o §0 certo\nporque §1 troca a multiplicação errada,\nentão leia a documentação de §2 para dicas de como resolver isso.", + "The music dies down. Is that it?\n\nCourse it isn't, you can\nclearly see that there are two levels left.\n\nA passing mathematician says that mathematicians don't have a name\nfor the structure you just constructed. You feel cheated.\n\nSuddenly the music starts up again. This really is the final boss.": + "A música vai diminuindo. Acabou?\n\nClaro que não, você consegue\nver claramente que ainda faltam dois níveis.\n\nUm matemático que passava por ali diz que os matemáticos não têm um nome\npara a estrutura que você acabou de construir. Você se sente enganado.\n\nDe repente a música recomeça. Este é mesmo o chefão final.", + "The lemma proved in the final level of this world will be helpful\nin Divisibility World.": + "O lema provado no nível final deste mundo vai ser útil\nno Mundo da Divisibilidade.", + "The inductive hypothesis §0 is \"For all natural numbers §1, §2\".\nYou can §3 it §4 any hypothesis of the form §5.": + "A hipótese indutiva §0 é \"Para todo número natural §1, §2\".\nVocê pode fazer §3 dela §4 qualquer hipótese da forma §5.", + "The goal in this level is one of our hypotheses. Solve the goal by executing §0.": + "O objetivo deste nível é uma das nossas hipóteses. Resolva o objetivo executando §0.", + "The first sub-boss of Multiplication World is §0.\n\nWhen you've proved this theorem we will have \"spare\" proofs\nsuch as §1, which is now easily deducible from §2.\nBut we'll keep hold of these proofs anyway, because it's convenient\nto have exactly the right tool for a job.": + "O primeiro sub-chefão do Mundo da Multiplicação é §0.\n\nQuando você tiver provado esse teorema, teremos provas \"sobressalentes\"\ncomo §1, que agora é facilmente dedutível de §2.\nMas vamos guardar essas provas mesmo assim, porque é conveniente\nter exatamente a ferramenta certa para cada trabalho.", + "The classical introduction game for Lean.": + "O clássico jogo para conhecer o Lean.", + "Start with §0. This will change §1 to §2.": + "Comece com §0. Isso vai transformar §1 para §2.", + "Start with §0.": "Comece com §0.", + "Start with §0, to change the goal into its\ncontrapositive, namely a hypothesis of §1 and a goal of §2.": + "Comece com §0, para transformar o objetivo na sua\ncontrapositiva, ou seja, uma hipótese §1 e um objetivo §2.", + "Start with §0 to push all the brackets to the right.": + "Comece com §0 para empurrar todos os parênteses para a direita.", + "Start with §0 to do a case split on §1 and §2.": + "Comece com §0 para fazer uma divisão em casos entre §1 e §2.", + "Start with §0 to begin to break §1 down into its definition.": + "Comece com §0 para começar a decompor §1 na sua definição.", + "Start with §0 to assume the hypothesis.": + "Comece com §0 para supor a hipótese.", + "Start with §0 to assume the hypothesis and call its proof §1.": + "Comece com §0 para supor a hipótese e chamar sua prova de §1.", + "Start with §0 to apply §1 to the *goal*.": + "Comece com §0 para aplicar §1 ao *objetivo*.", + "Start with §0 and §1": "Comece com §0 e §1", + "Start with §0 and take it from there.": "Comece com §0 e siga a partir daí.", + "Start with §0 (remembering that §1 is just notation\nfor §2).": + "Comece com §0 (lembrando que §1 é apenas notação\npara §2).", + "Start with induction on §0.": "Comece com indução em §0.", + "Start by unravelling the §0.": "Comece desembrulhando o §0.", + "Split into cases §0 and §1 with §2.": "Divida nos casos §0 e §1 com §2.", + "Solve this level in one line with §0": + "Resolva este nível em uma linha com §0", + "So that's the algorithm: now let's use automation to perform it\nautomatically.": + "Esse é o algoritmo: agora vamos usar automação para executá-lo\nautomaticamente.", + "Similarly we have §0\nbut we're going to need §1 (guess what it says -- maybe you\nare getting the hang of Lean's naming conventions).\n\nThe last level from addition world might help you in this level.\nIf you can't remember what it is, you can go back to the\nhome screen by clicking the house icon and then taking a look.\nYou won't lose any progress.": + "De modo semelhante, temos §0,\nmas vamos precisar de §1 (adivinhe o que ele diz -- talvez você\nesteja pegando o jeito das convenções de nomes de Lean).\n\nO último nível do Mundo da Adição pode te ajudar neste nível.\nSe você não lembra qual é, pode voltar para a\ntela inicial clicando no ícone da casa e dar uma olhada.\nVocê não vai perder nenhum progresso.", + "See the new \"*\" tab in your lemmas, containing §0 and §1.\nRight now these are the only facts we know about multiplication.\nLet's prove nine more.\n\nLet's start with a warm-up: no induction needed for this one,\nbecause we know §2 is a successor.": + "Veja a nova aba \"*\" nos seus lemas, contendo §0 e §1.\nNeste momento esses são os únicos fatos que conhecemos sobre multiplicação.\nVamos provar mais nove.\n\nComecemos com um aquecimento: não é preciso indução para este,\nporque sabemos que §2 é um sucessor.", + "See if you can take it from here. Look at the new lemmas and tactic\navailable on the right.": + "Veja se você consegue seguir daqui. Olhe os novos lemas e a nova tática\ndisponíveis à direita.", + "Remember, §0 is *notation* for §1.": "Lembre-se: §0 é *notação* para §1.", + "Remember that §0 is a proof of §1. Try\n§2ing §3 either §4 or directly to the goal.": + "Lembre que §0 é uma prova de §1. Tente\nusar §2 com §3, seja §4 ou diretamente no objetivo.", + "Remember that when Lean writes §0, it means §1.\nIf you are not sure where the brackets are in an expression, just hover\nyour cursor over it and look at what gets highlighted. For example,\nhover over both §2 symbols on the left hand side of the goal and\nyou'll see where the invisible brackets are.": + "Lembre-se de que quando o Lean escreve §0, ele quer dizer §1.\nSe você não tem certeza de onde estão os parênteses em uma expressão, basta passar\no mouse sobre ela e ver o que fica destacado. Por exemplo,\npasse o mouse sobre os dois símbolos §2 no lado esquerdo do objetivo e\nvocê vai ver onde estão os parênteses invisíveis.", + "Reduce to the previous lemma with §0": "Reduza ao lema anterior com §0", + "Ready for the boss level of this world?": "Pronto para o chefão deste mundo?", + "Proofs like §0 and §1 are very tedious to do by hand.\nIn Algorithm World we learn how to get the computer to do them for us.\n\nClick on \"Start\" to proceed.": + "Provas como §0 e §1 são bem tediosas de fazer na mão.\nNo Mundo dos Algoritmos aprendemos como fazer o computador fazê-las por nós.\n\nClique em \"Começar\" para continuar.", + "Precision rewriting": "Reescrita com precisão", + "Power World": "Mundo da Potência", + "Our next goal is \"left and right distributivity\",\nmeaning §0 and §1. Rather than\nthese slightly pompous names, the name of the proofs\nin Lean are descriptive. Let's start with\n§2, the proof of §3.\nNote that the left hand side contains a multiplication\nand then an addition.": + "Nosso próximo objetivo é a \"distributividade à esquerda e à direita\",\nou seja, §0 e §1. Em vez desses\nnomes um tanto pomposos, os nomes das provas\nem Lean são descritivos. Vamos começar com\n§2, a prova de §3.\nNote que o lado esquerdo contém uma multiplicação\ne depois uma adição.", + "Our first challenge is §0,\nand we want to prove it by induction. The zero\ncase will need §1 (which we have)\nand §2 (which we don't), so let's\nstart with this.": + "Nosso primeiro desafio é §0,\ne queremos provar isso por indução. O caso zero\nvai precisar de §1 (que já temos)\ne de §2 (que não temos), então vamos\ncomeçar por aí.", + "One of the best named levels in the game, a savage §0\nsub-boss appears as the music reaches a frenzy. What\nelse could there be to prove about powers after this?": + "Um dos níveis com o melhor nome do jogo: um selvagem sub-chefão §0\naparece enquanto a música chega ao frenesi. O que mais\npoderia restar para provar sobre potências depois disso?", + "One day this game will have a Prime Number World, with a final boss\nof proving that §0 is prime.\nTo do this, we will have to rule out things like §1\nWe will do this by proving that any factor of §2 is at most §3,\nwhich we will do using this lemma. The proof I have in mind manipulates the hypothesis\nuntil it becomes the goal, using §4, §5 and\n§6.": + "Um dia este jogo vai ter um Mundo dos Números Primos, com um chefão final\nque é provar que §0 é primo.\nPara isso, vamos ter que descartar coisas como §1\nVamos fazer isso provando que qualquer fator de §2 é no máximo §3,\no que faremos usando este lema. A prova que tenho em mente manipula a hipótese\naté ela virar o objetivo, usando §4, §5 e\n§6.", + "On the set of natural numbers, addition is commutative.\nIn other words, if §0 and §1 are arbitrary natural numbers, then\n§2.": + "No conjunto dos números naturais, a adição é comutativa.\nEm outras palavras, se §0 e §1 são números naturais arbitrários, então\n§2.", + "On the set of natural numbers, addition is associative.\nIn other words, if §0 and §1 are arbitrary natural numbers, we have\n§2": + "No conjunto dos números naturais, a adição é associativa.\nEm outras palavras, se §0 e §1 são números naturais arbitrários, temos\n§2", + "Oh no! On the way to §0, a wild §1 appears. §2\nis the proof that §3 for §4 and §5 numbers.\nThis result is what's standing in the way of §6. Again\nwe have the problem that we are adding §7 to things, so we need\nto use induction to split into the cases where §8 and §9 is a successor.": + "Ah, não! No caminho para §0, um §1 selvagem aparece. §2\né a prova de que §3 para §4 e §5 números.\nEsse resultado é o que está no caminho de §6. De novo\ntemos o problema de estarmos somando §7 às coisas, então precisamos\nusar indução para separar nos casos em que §8 e em que §9 é um sucessor.", + "Numbers": "Números", + "Now §0.": "Agora faça §0.", + "Now §0 will work.": "Agora §0 vai funcionar.", + "Now §0 will change §1 into §2.": "Agora §0 vai transformar §1 em §2.", + "Now §0 to cancel the §1s.": "Agora faça §0 para cancelar os §1.", + "Now §0 then §1 works, but §2 is quicker.": + "Agora §0 e depois §1 funciona, mas §2 é mais rápido.", + "Now §0 so you can §1.": "Agora faça §0, para você poder fazer §1.", + "Now §0 is the quickest way to\nchange §1 to §2.": + "Agora §0 é o jeito mais rápido de\ntransformar §1 em §2.", + "Now §0 is a proof that §1, and §2 has vanished. Similarly, you can destruct\n§3 into its parts with §4.": + "Agora §0 é uma prova de que §1, e §2 sumiu. Do mesmo jeito, você pode destrinchar\n§3 em suas partes com §4.", + "Now §0 finishes the job.": "Agora §0 termina o serviço.", + "Now §0 and you can probably take it from here.": + "Agora você faz §0 e provavelmente consegue seguir daqui.", + "Now §0 and deal with the two\ncases separately.": + "Agora faça §0 e trate os dois\ncasos separadamente.", + "Now you need to figure out which number to §0. See if you can take it from here.": + "Agora você precisa descobrir qual número usar no §0. Veja se você consegue seguir daqui.", + "Now you have two goals. Once you proved the first, you will jump to the second one.\nThis first goal is the base case §0.\n\nRecall that you can rewrite the proof of any lemma which is visible\nin your inventory, or of any assumption displayed above the goal,\nas long as it is of the form §1.": + "Agora você tem dois objetivos. Assim que provar o primeiro, você pula para o segundo.\nEste primeiro objetivo é o caso base §0.\n\nLembre que você pode reescrever a prova de qualquer lema que esteja visível\nno seu inventário, ou de qualquer hipótese exibida acima do objetivo,\ndesde que ela seja da forma §1.", + "Now you could finish with §0 then §1, but §2\ndoes it in one line.": + "Agora você poderia terminar com §0 e depois §1, mas §2\nfaz isso em uma linha só.", + "Now you can §0.": "Agora você pode fazer §0.", + "Now you can §0": "Agora você pode fazer §0", + "Now we can prove the §0 statement by proving the statement on the right,\nso use the §1 tactic.": + "Agora podemos provar o enunciado com §0 provando o enunciado da direita,\nentão use a tática §1.", + "Now use §0 to switch §1 and §2 on the left\nhand side.": + "Agora use §0 para trocar §1 e §2 no lado\nesquerdo.", + "Now the goal can be deduced from §0 by pure logic, so use the §1\ntactic.": + "Agora o objetivo pode ser deduzido de §0 por lógica pura, então use a tática §1.", + "Now take apart the existence statement with §0.": + "Agora desmonte o enunciado de existência com §0.", + "Now rewrite §0 backwards to make the goal\nequal to the hypothesis.": + "Agora reescreva §0 de trás para frente para deixar o objetivo\nigual à hipótese.", + "Now rewrite §0 backwards at §1\nto get the right hand side.": + "Agora reescreva §0 de trás para frente em §1\npara obter o lado direito.", + "Now let's §0 our new theorem. Execute §1\nto change §2 to a proof of §3.": + "Agora vamos usar §0 no nosso novo teorema. Execute §1\npara transformar §2 numa prova de §3.", + "Now for the second goal. Here you have the induction hypothesis\n§0, and you need to prove that §1.": + "Agora o segundo objetivo. Aqui você tem a hipótese de indução\n§0, e precisa provar que §1.", + "Now finish using the §0 tactic.": "Agora termine usando a tática §0.", + "Now finish the job with §0.": "Agora termine o serviço com §0.", + "Now finish in one line.": "Agora termine em uma linha.", + "Now change §0 to §1 in §2.": "Agora troque §0 por §1 em §2.", + "Note: this lemma will be useful for the final boss!": + "Nota: este lema será útil para o chefão final!", + "Note that §0 means §1. Put your cursor\non any §2 in the goal or assumptions to see what exactly it's eating.": + "Note que §0 significa §1. Coloque o cursor\nsobre qualquer §2 no objetivo ou nas hipóteses para ver exatamente o que ele está comendo.", + "Note that you can do §0\nand then §1 to solve this level in two lines.": + "Note que você pode fazer §0\ne depois §1 para resolver este nível em duas linhas.", + "Nice! You've proved §0!\nLet's now prove Peano's other axiom, that successors can't be §1.": + "Muito bem! Você provou §0!\nAgora vamos provar o outro axioma de Peano, de que sucessores não podem ser §1.", + "Nice!\n\nThe next step in the development of order theory is to develop\nthe theory of the interplay between §0 and multiplication.\nIf you've already done Multiplication World, you're now ready for\nAdvanced Multiplication World. Click on \"Leave World\" to access it.": + "Muito bem!\n\nO próximo passo no desenvolvimento da teoria da ordem é desenvolver\na teoria da interação entre §0 e a multiplicação.\nSe você já passou pelo Mundo da Multiplicação, agora está pronto para\no Mundo da Multiplicação Avançada. Clique em \"Leave World\" para acessá-lo.", + "Nice!": "Muito bem!", + "Next turn §0 into §1 with §2.": "Em seguida transforme §0 em §1 com §2.", + "Natural Number Game": "Jogo dos Números Naturais", + "My proof:\n§0": "Minha prova:\n§0", + "Multiplication usually makes a number bigger, but multiplication by zero can make\nit smaller. Thus many lemmas about inequalities and multiplication need the\nhypothesis §0. Here is a key lemma that enables us to use this hypothesis.\nTo help us with the proof, we can use the §1 tactic. Click on the tactic's name\non the right to see what it does.": + "A multiplicação geralmente deixa um número maior, mas a multiplicação por zero pode deixá-lo\nmenor. Por isso muitos lemas sobre desigualdades e multiplicação precisam da\nhipótese §0. Aqui está um lema chave que nos permite usar essa hipótese.\nPara nos ajudar na prova, podemos usar a tática §1. Clique no nome da tática\nà direita para ver o que ela faz.", + "Multiplication is distributive over addition on the left.\nIn other words, for all natural numbers §0, §1 and §2, we have\n§3.": + "A multiplicação é distributiva sobre a adição à esquerda.\nEm outras palavras, para quaisquer números naturais §0, §1 e §2, temos\n§3.", + "Multiplication is commutative.": "A multiplicação é comutativa.", + "Multiplication is associative.\nIn other words, for all natural numbers §0, §1 and §2, we have\n§3.": + "A multiplicação é associativa.\nEm outras palavras, para quaisquer números naturais §0, §1 e §2, temos\n§3.", + "Multiplication distributes\nover addition on the left.\n\n§0 is the proof that §1.": + "A multiplicação é distributiva\nsobre a adição à esquerda.\n\n§0 é a prova de que §1.", + "Multiplication World": "Mundo da Multiplicação", + "Mathematicians sometimes debate what §0 is;\nthe answer depends, of course, on your definitions. In this\ngame, §1. See if you can prove it.\n\nCheck out the *Pow* tab in your list of theorems\nto see the new proofs which are available.": + "Os matemáticos às vezes discutem quanto vale §0;\na resposta depende, é claro, das suas definições. Neste\njogo, §1. Veja se você consegue provar isso.\n\nDê uma olhada na aba *Pow* na sua lista de teoremas\npara ver as novas provas disponíveis.", + "Mathematicians sometimes argue that §0 is also\na good convention. But it is not a good convention in this\ngame; all the later levels come out beautifully with the\nconvention that §1.": + "Matemáticos às vezes argumentam que §0 também\né uma boa convenção. Mas ela não é uma boa convenção neste\njogo; todos os níveis seguintes ficam lindos com a\nconvenção de que §1.", + "Many people find §0 easy, but some find §1 confusing.\nIf you find it confusing, then just argue forwards.\n\nYou can read more about the §2 tactic in its documentation, which you can view by\nclicking on the tactic in the list on the right.": + "Muita gente acha §0 fácil, mas algumas pessoas acham §1 confuso.\nSe você achar confuso, então argumente para frente.\n\nVocê pode ler mais sobre a tática §2 na documentação dela, que você pode ver\nclicando na tática na lista à direita.", + "Let's warm up with an easy one, which works even if §0.": + "Vamos aquecer com um fácil, que vale mesmo se §0.", + "Let's see if you can use the tactics we've learnt to prove §0.\nTry this one by yourself; if you need help then click on \"Show more help!\".": + "Vamos ver se você consegue usar as táticas que aprendemos para provar §0.\nTente este sozinho; se precisar de ajuda, clique em \"Mostrar mais ajuda!\".", + "Let's now move on to a more efficient approach to questions\ninvolving numerals, such as §0.": + "Vamos agora partir para uma abordagem mais eficiente para questões\nenvolvendo numerais, como §0.", + "Let's now make our own tactic to do this.": + "Vamos agora criar nossa própria tática para fazer isso.", + "Let's now learn about Peano's second axiom for addition, §0.": + "Vamos agora aprender o segundo axioma de Peano para a adição, §0.", + "Let's now begin our approach to the final boss,\nby proving some more subtle facts about powers.": + "Vamos agora começar a nos aproximar do chefão final,\nprovando alguns fatos mais sutis sobre potências.", + "Let's first get §0 into the form §1 so we can\napply §2. First execute §3\nto change the 4 on the right hand side.": + "Vamos primeiro colocar §0 na forma §1 para podermos\naplicar §2. Primeiro execute §3\npara mudar o 4 do lado direito.", + "Lean's simplifier, §0, is \"§1 on steroids\". It will rewrite every lemma\ntagged with §2 and every lemma fed to it by the user, as much as it can.\n\nThis level is not a level which you want to solve by hand.\nGet the simplifier to solve it for you.": + "O simplificador de Lean, §0, é o \"§1 turbinado\". Ele vai reescrever todo lema\nmarcado com §2 e todo lema fornecido pelo usuário, tanto quanto conseguir.\n\nEste nível não é um nível que você queira resolver na mão.\nFaça o simplificador resolvê-lo para você.", + "It's all over! You have proved a theorem which has tripped up\nschoolkids for generations (some of them think §0:\nthis is \"the freshman's dream\").\n\nHow many rewrites did you use? I can do it in 12.\n\nBut wait! This boss is stirring...and mutating into a second more powerful form!": + "Acabou! Você provou um teorema que derrubou\ngerações de estudantes (alguns deles acham que §0:\nesse é o \"sonho do calouro\").\n\nQuantas reescritas você usou? Eu consigo em 12.\n\nMas espere! Este chefão está se mexendo... e se transformando numa segunda forma mais poderosa!", + "It's \"intuitively obvious\" that there are no numbers less than zero,\nbut to prove it you will need a result which you showed in advanced\naddition world.": + "É \"intuitivamente óbvio\" que não existem números menores que zero,\nmas para provar isso você vai precisar de um resultado que você mostrou no\nMundo da Adição Avançada.", + "Induction on §0 or §1 -- it's all the same in this one.": + "Indução em §0 ou §1 -- neste aqui dá na mesma.", + "Induction on §0 is the most troublesome, then §1,\nand §2 is the easiest.": + "A indução em §0 é a mais trabalhosa, depois §1,\ne §2 é a mais fácil.", + "In this world we'll learn how to prove theorems of the form §0.\nIn other words, how to prove theorems of the form \"if §1 is true, then §2 is true.\"\nTo do that we need to learn some more tactics.\n\nThe §3 tactic can be used to close a goal which is exactly one of\nthe hypotheses. It takes the name of the hypothesis as argument: §4.": + "Neste mundo vamos aprender a provar teoremas da forma §0.\nEm outras palavras, como provar teoremas da forma \"se §1 é verdadeiro, então §2 é verdadeiro.\"\nPara isso precisamos aprender mais algumas táticas.\n\nA tática §3 pode ser usada para fechar um objetivo que é exatamente uma\ndas hipóteses. Ela recebe o nome da hipótese como argumento: §4.", + "In this world we define §0 and prove standard facts\nabout it, such as \"if §1 and §2 then §3.\"\n\nThe definition of §4 is \"there exists a number §5\nsuch that §6. \" So we're going to have to learn\na tactic to prove \"exists\" theorems, and another one\nto use \"exists\" hypotheses.\n\nClick on \"Start\" to proceed.": + "Neste mundo definimos §0 e provamos fatos padrão\nsobre isso, como \"se §1 e §2 então §3.\"\n\nA definição de §4 é \"existe um número §5\ntal que §6. \" Então vamos ter que aprender\numa tática para provar teoremas de \"existe\", e outra\npara usar hipóteses de \"existe\".\n\nClique em \"Começar\" para prosseguir.", + "In this world I will mostly leave you on your own.\n\n§0 is the theorem that §1.": + "Neste mundo, vou deixar você por sua própria conta na maior parte do tempo.\n\n§0 é o teorema de que §1.", + "In this level, we see inequalities as *hypotheses*. We have not seen this before.\nThe §0 tactic can be used to take §1 apart.": + "Neste nível, vemos desigualdades como *hipóteses*. Não tínhamos visto isso antes.\nA tática §0 pode ser usada para desmontar §1.", + "In this level, the hypotheses §0 is an *implication*. It says\nthat *if* §1 *then* §2. We can use this\nhypothesis with the §3 tactic. Remember you can click on\n§4 or any other tactic on the right to see a detailed explanation\nof what it does, with examples.": + "Neste nível, a hipótese §0 é uma *implicação*. Ela diz\nque *se* §1 *então* §2. Podemos usar essa\nhipótese com a tática §3. Lembre que você pode clicar em\n§4 ou em qualquer outra tática à direita para ver uma explicação detalhada\ndo que ela faz, com exemplos.", + "In this level we're going to prove that §0, where §1 is a secret natural number.\n\nWait, don't we already know that? No! We know that §2, but that's §3.\nThis is §4, which is different.\n\nThe difficulty with proving §5 is that we do not have a *formula* for\n§6 in general, we can only use §7 and §8 once\nwe know whether §9 is §10 or a successor. The §11 tactic splits into these two cases.\n\nThe base case will require us to prove §12, and the inductive step\nwill ask us to show that if §13 then §14. Because\n§15 and successor are the only way to make numbers, this will cover all the cases.\n\nSee if you can do your first induction proof in Lean.\n\n(By the way, if you are still in the \"Editor mode\" from the last world, you can swap\nback to \"Typewriter mode\" by clicking the §16 button in the top right.)": + "Neste nível vamos provar que §0, onde §1 é um número natural secreto.\n\nEspera, a gente já não sabe disso? Não! Sabemos que §2, mas isso é §3.\nAqui é §4, que é diferente.\n\nA dificuldade de provar §5 é que não temos uma *fórmula* para\n§6 em geral; só podemos usar §7 e §8 quando\nsabemos se §9 é §10 ou um sucessor. A tática §11 divide nesses dois casos.\n\nO caso base vai exigir que provemos §12, e o passo indutivo\nvai pedir que mostremos que se §13 então §14. Como\n§15 e o sucessor são as únicas formas de construir números, isso cobre todos os casos.\n\nVeja se você consegue fazer sua primeira prova por indução em Lean.\n\n(A propósito, se você ainda estiver no \"Editor mode\" do mundo anterior, pode voltar\npara o \"Typewriter mode\" clicando no botão §16 no canto superior direito.)", + "In this level we prove that if §0 and §1 then §2. It is tricky, for\nseveral reasons. One of these is that\nwe need to introduce a new idea: we will need to understand the concept of\nmathematical induction a little better.\n\nStarting with §3 is too naive, because in the inductive step\nthe hypothesis is §4 but what we know is §5,\nso the induction hypothesis does not apply!\n\nAssume §6 is fixed. The actual statement we want to prove by induction on §7 is\n\"for all §8, if §9 then §10\". This *can* be proved by induction,\nbecause we now have the flexibility to change §11.": + "Neste nível provamos que se §0 e §1, então §2. É complicado, por\nvárias razões. Uma delas é que\nprecisamos introduzir uma ideia nova: vamos precisar entender um pouco melhor\no conceito de indução matemática.\n\nComeçar com §3 é ingênuo demais, porque no passo indutivo\na hipótese é §4 mas o que sabemos é §5,\nentão a hipótese de indução não se aplica!\n\nSuponha que §6 esteja fixo. O enunciado que realmente queremos provar por indução em §7 é\n\"para todo §8, se §9 então §10\". Isso *pode* ser provado por indução,\nporque agora temos a flexibilidade de mudar §11.", + "In this level the *goal* is §0 but to help us we\nhave an *assumption* §1 saying that §2. Check that you can see §3 in\nyour list of assumptions. Lean thinks of §4 as being a secret proof of the\nassumption, rather like §5 is a secret number.\n\nBefore we can use §6, we have to \"substitute in for §7\".\nWe do this in Lean by *rewriting* the proof §8,\nusing the §9 tactic.": + "Neste nível o *objetivo* é §0, mas para nos ajudar temos\numa *hipótese* §1 dizendo que §2. Verifique que você consegue ver §3 na\nsua lista de hipóteses. O Lean pensa em §4 como uma prova secreta da\nhipótese, mais ou menos como §5 é um número secreto.\n\nAntes de podermos usar §6, temos que \"substituir §7\".\nFazemos isso em Lean *reescrevendo* usando a prova §8,\ncom a tática §9.", + "In this game you recreate the natural numbers §0 from the Peano axioms,\nlearning the basics about theorem proving in Lean.\n\nThis is a good first introduction to Lean!": + "Neste jogo você recria os números naturais §0 a partir dos axiomas de Peano,\naprendendo o básico sobre como provar teoremas em Lean.\n\nEsta é uma boa primeira introdução ao Lean!", + "In the next level, we'll do the same proof but backwards.": + "No próximo nível, faremos a mesma prova, mas de trás para frente.", + "In the last level, we manipulated the hypothesis §0\n until it became the goal §1. In this level we'll manipulate\n the goal until it becomes our hypothesis! In other words, we\n will \"argue backwards\". The §2 tactic can do this too.\n Again I will walk you through this one (assuming you're in\n command line mode).": + "No nível anterior, manipulamos a hipótese §0\n até ela virar o objetivo §1. Neste nível vamos manipular\n o objetivo até ele virar a nossa hipótese! Em outras palavras, vamos\n \"argumentar de trás para frente\". A tática §2 também consegue fazer isso.\n De novo, vou te guiar por este (supondo que você esteja no\n modo linha de comando).", + "In the \"base case\" we have a hypothesis §0, and you can deduce anything\nfrom a false statement. The §1 tactic will close this goal.": + "No \"caso base\" temos uma hipótese §0, e você pode deduzir qualquer coisa\na partir de um enunciado falso. A tática §1 vai fechar esse objetivo.", + "In some later worlds, we're going to see some much nastier levels,\nlike §0.\nBrackets need to be moved around, and variables need to be swapped.\n\nIn this level, §1,\nlet's forget about the brackets and just think about\nthe variable order.\nTo turn §2 into §3 we need to swap §4 and §5,\nand then swap §6 and §7. But this is easier than you\nthink with §8.": + "Em alguns mundos mais adiante, vamos ver níveis bem mais desagradáveis,\ncomo §0.\nParênteses precisam ser movidos, e variáveis precisam ser trocadas de lugar.\n\nNeste nível, §1,\nvamos esquecer os parênteses e pensar apenas\nna ordem das variáveis.\nPara transformar §2 em §3 precisamos trocar §4 e §5,\ne depois trocar §6 e §7. Mas isso é mais fácil do que você\npensa com §8.", + "In order to use the tactic §0 you can enter it in the text box\nunder the goal and hit \"Execute\".": + "Para usar a tática §0 você pode digitá-la na caixa de texto\nabaixo do objetivo e clicar em \"Execute\".", + "In Advanced Addition World we will prove some basic\naddition facts such as §0. The theorems\nproved in this world will be used to build\na theory of inequalities in §1 World.\n\nClick on \"Start\" to proceed.": + "No Mundo da Adição Avançada vamos provar alguns fatos básicos\nsobre adição, como §0. Os teoremas\nprovados neste mundo serão usados para construir\numa teoria de desigualdades no Mundo do §1.\n\nClique em \"Começar\" para continuar.", + "Implication World": "Mundo da Implicação", + "Implementing the algorithm for equality of naturals, and the proof that it is correct,\nlooks like this:\n\n§0\n\nThis Lean code is a formally verified algorithm for deciding equality\nbetween two naturals. I've typed it in already, behind the scenes.\nBecause the algorithm is formally verified to be correct, we can\nuse it in Lean proofs. You can run the algorithm with the §1 tactic.": + "Implementar o algoritmo para igualdade de naturais, junto com a prova de que ele está correto,\nfica assim:\n\n§0\n\nEsse código Lean é um algoritmo formalmente verificado para decidir a igualdade\nentre dois naturais. Eu já digitei ele, nos bastidores.\nComo o algoritmo é formalmente verificado como correto, podemos\nusá-lo em provas Lean. Você pode rodar o algoritmo com a tática §1.", + "If §0, §1 and §2 are numbers, we have\n§3": + "Se §0, §1 e §2 são números, temos\n§3", + "If §0, then §1.": "Se §0, então §1.", + "If §0 then §1.": "Se §0 então §1.", + "If §0 then §1 or §2 or §3.": "Se §0 então §1 ou §2 ou §3.", + "If §0 then either §1 or §2.": "Se §0 então §1 ou §2.", + "If §0 or §1, then §2 or §3.": "Se §0 ou §1, então §2 ou §3.", + "If §0 is a proof of §1 then §2 will\nturn §3s into §4s. But what if we want to\nturn §5s into §6s? To tell the §7 tactic\nwe want this, we use a left arrow §8. Type\n§9 and then hit the space bar to get this arrow.\n\nLet's prove that §10 is the number after the number\nafter §11 again, this time by changing §12\ninto §13.": + "Se §0 é uma prova de §1, então §2 vai\ntransformar §3 em §4. Mas e se quisermos\ntransformar §5 em §6? Para dizer à tática §7\nque é isso que queremos, usamos uma seta para a esquerda §8. Digite\n§9 e aperte a barra de espaço para obter essa seta.\n\nVamos provar de novo que §10 é o número depois do número\ndepois de §11, desta vez transformando §12\nem §13.", + "If §0 is a number, then §1.": "Se §0 é um número, então §1.", + "If §0 are numbers, then §1.": "Se §0 são números, então §1.", + "If §0 are arbitrary natural numbers, we have\n§1.": + "Se §0 são números naturais arbitrários, temos\n§1.", + "If §0 and §1, then §2.": "Se §0 e §1, então §2.", + "If §0 and §1 then we can deduce a contradiction.": + "Se §0 e §1 então podemos deduzir uma contradição.", + "If §0 and §1 are numbers, then §2 is a proof\nthat §3 implies §4. Click on this theorem in the *Peano*\ntab for more information.\n\nPeano had this theorem as an axiom, but in Algorithm World\nwe will show how to prove it in Lean. Right now let's just assume it,\nand let's prove §5 using it. Again, we will proceed\nby manipulating our hypothesis until it becomes the goal. I will\nwalk you through this level.": + "Se §0 e §1 são números, então §2 é a prova\nde que §3 implica §4. Clique neste teorema na aba *Peano*\npara mais informações.\n\nPeano tinha este teorema como axioma, mas no Mundo dos Algoritmos\nvamos mostrar como prová-lo em Lean. Por enquanto vamos só assumi-lo,\ne vamos provar §5 usando ele. De novo, vamos proceder\nmanipulando nossa hipótese até que ela se torne o objetivo. Vou\nte guiar por este nível.", + "If §0 and §1 are numbers, then either §2 or §3.": + "Se §0 e §1 são números, então §2 ou §3.", + "If §0 and §1 are natural numbers, and §2, then §3.": + "Se §0 e §1 são números naturais, e §2, então §3.", + "If §0 and §1 are arbitrary natural numbers, we have\n§2.": + "Se §0 e §1 são números naturais arbitrários, temos\n§2.", + "If §0 and §1 are arbitrary natural numbers, then §2": + "Se §0 e §1 são números naturais arbitrários, então §2", + "If §0 and we know that §1 then we can deduce §2.": + "Se §0 e sabemos que §1 então podemos deduzir §2.", + "If you §0 the wrong number, you get stuck with a goal you can't prove.\nWhat number will you §1 here?": + "Se você usar §0 com o número errado, fica preso com um objetivo que não consegue provar.\nQual número você vai usar no §1 aqui?", + "If you have completed Algorithm World then you can use the §0 tactic\nhere. If not then I'll talk you through a manual approach.": + "Se você completou o Mundo dos Algoritmos, então pode usar a tática §0\naqui. Se não, vou te guiar por uma abordagem manual.", + "If the goal is not *exactly* a hypothesis, we can sometimes\nuse rewrites to fix things up.": + "Se o objetivo não é *exatamente* uma hipótese, às vezes podemos\nusar reescritas para ajeitar as coisas.", + "How should we define §0? Just like addition, we need to give definitions\nwhen §1 and when §2 is a successor.\n\nThe zero case is easy: we define §3 to be §4. Now say we know\n§5. What should §6 be? Well, that's §7 §8s,\nso it should be §9.\n\nHere are the definitions in Lean.\n\n * §10\n * §11\n\nIn this world, we must not only prove facts about multiplication like §12,\nwe must also prove facts about how multiplication interacts with addition, like §13.\nLet's get started.": + "Como devemos definir §0? Assim como na adição, precisamos dar definições\npara quando §1 e para quando §2 é um sucessor.\n\nO caso zero é fácil: definimos §3 como §4. Agora suponha que sabemos\n§5. Quanto deveria ser §6? Bem, isso é §7 §8s,\nentão deveria ser §9.\n\nAqui estão as definições em Lean.\n\n * §10\n * §11\n\nNeste mundo, não devemos apenas provar fatos sobre multiplicação como §12,\ndevemos também provar fatos sobre como a multiplicação interage com a adição, como §13.\nVamos começar.", + "How about this for a proof:\n§0": "Que tal esta prova:\n§0", + "How about this for a proof:\n\n§0\n\nThat's the end of Advanced Addition World! You'll need these theorems\nfor the next world, §1 World. Click on \"Leave World\" to access it.": + "Que tal esta prova:\n\n§0\n\nEsse é o fim do Mundo da Adição Avançada! Você vai precisar destes teoremas\nno próximo mundo, o Mundo do §1. Clique em \"Leave World\" para acessá-lo.", + "Here's what I was thinking of:\n§0": "Eu pensei assim:\n§0", + "Here's the short proof:\n§0\nThis works because, given §1,\nthe argument is reduced to pure logic.": + "Aqui está a prova curta:\n§0\nIsso funciona porque, dado §1,\no argumento se reduz a pura lógica.", + "Here's my solution:\n§0\n\nInducting on §1 or §2 also works, but might take longer.": + "Aqui está a minha solução:\n§0\n\nFazer indução em §1 ou §2 também funciona, mas pode dar mais trabalho.", + "Here's my solution:\n§0": "Esta é a minha solução:\n§0", + "Here's my proof:\n§0\n\nIf you solved this level then you should be fine with the next level!": + "Aqui está a minha prova:\n§0\n\nSe você resolveu este nível, então vai se dar bem no próximo!", + "Here's my proof:\n§0\n\nEven though Lean is a theorem prover, right now it's pretty clear that we have not\ndeveloped enough material to make it an adequate calculator. In Algorithm\nWorld, a more computer-sciency world, we will develop machinery which makes\nquestions like this much easier, and goals like §1 feasible.\nAlternatively you can do more mathematics in Advanced Addition World, where we prove\nthe lemmas needed to get a working theory of inequalities. Click \"Leave World\" and\ndecide your route.": + "Aqui está a minha prova:\n§0\n\nMesmo o Lean sendo um provador de teoremas, agora está bem claro que ainda não\ndesenvolvemos material suficiente para torná-lo uma calculadora adequada. No Mundo dos\nAlgoritmos, um mundo mais de ciência da computação, vamos desenvolver ferramentas que tornam\nperguntas como esta bem mais fáceis, e objetivos como §1 viáveis.\nComo alternativa, você pode fazer mais matemática no Mundo da Adição Avançada, onde provamos\nos lemas necessários para ter uma teoria funcional das desigualdades. Clique em \"Leave World\" e\ndecida o seu caminho.", + "Here's my proof:\n§0\n\nA passing mathematician remarks that with antisymmetry as well,\nyou have proved that §1 is a *partial order* on §2.\n\nThe boss level of this world is to prove\nthat §3 is a total order. Let's learn two more easy tactics\nfirst.": + "Aqui está a minha prova:\n§0\n\nUm matemático que passava por aqui observa que, junto com a antissimetria,\nvocê provou que §1 é uma *ordem parcial* em §2.\n\nO chefão deste mundo é provar\nque §3 é uma ordem total. Vamos aprender mais duas táticas fáceis\nantes disso.", + "Here's my proof:\n§0": "Aqui está a minha prova:\n§0", + "Here's a two-liner:\n§0\n\nThis works because §1 is a proof of §2.": + "Aqui vai uma solução de duas linhas:\n§0\n\nIsso funciona porque §1 é uma prova de §2.", + "Here's a two-line proof:\n§0": "Aqui está uma prova de duas linhas:\n§0", + "Here's a proof using §0:\n§1\n\nand here's an even shorter one using the same idea:\n§2\n\nAlternatively you can just prove it by induction on §3:\n\n§4": + "Aqui está uma prova usando §0:\n§1\n\ne aqui está uma ainda mais curta usando a mesma ideia:\n§2\n\nComo alternativa, você pode simplesmente provar por indução em §3:\n\n§4", + "Here's a completely backwards proof:\n§0": + "Aqui está uma prova completamente de trás para frente:\n§0", + "Here we want to deal with the cases §0 and §1 separately,\nso start with §2.": + "Aqui queremos tratar os casos §0 e §1 separadamente,\nentão comece com §2.", + "Here we begin to\ndevelop an algorithm which, given two naturals §0 and §1, returns the answer\nto \"does §2?\"\n\nHere is the algorithm. First note that §3 and §4 are numbers, and hence\nare either §5 or successors.\n\n*) If §6 and §7 are both §8, return \"yes\".\n\n*) If one is §9 and the other is §10, return \"no\".\n\n*) If §11 and §12, then return the answer to \"does §13?\"\n\nOur job now is to *prove* that this algorithm always gives the correct answer. The proof that\n§14 is §15. The proof that §16 is §17, and the proof\nthat §18 is §19. The proof that if §20 then\n§21 is §22 and then §23. This level is a proof of the one\nremaining job we have to do: if §24 then §25.": + "Aqui começamos a\ndesenvolver um algoritmo que, dados dois naturais §0 e §1, devolve a resposta\npara \"será que §2?\"\n\nEis o algoritmo. Primeiro note que §3 e §4 são números e, portanto,\nsão §5 ou sucessores.\n\n*) Se §6 e §7 forem ambos §8, devolva \"sim\".\n\n*) Se um for §9 e o outro for §10, devolva \"não\".\n\n*) Se §11 e §12, então devolva a resposta para \"será que §13?\"\n\nNosso trabalho agora é *provar* que esse algoritmo sempre dá a resposta correta. A prova de que\n§14 é §15. A prova de que §16 é §17, e a prova\nde que §18 é §19. A prova de que, se §20, então\n§21 é §22 e depois §23. Este nível é a prova da única\ntarefa que nos resta: se §24 então §25.", + "Here is an example proof of 2+2=4 showing off various techniques.\n\n§0\n\nOptional extra: you can run this proof yourself. Switch the game into \"Editor mode\" by clicking\non the §1 button in the top right. You can now see your proof\nwritten as several lines of code. Move your cursor between lines to see\nthe goal state at any point. Now cut and paste your code elsewhere if you\nwant to save it, and paste the above proof in instead. Move your cursor\naround to investigate. When you've finished, click the §2 button in the top right to\nmove back into \"Typewriter mode\".\n\nYou have finished tutorial world!\nClick \"Leave World\" to go back to the\noverworld, and select Addition World, where you will learn\nabout the §3 tactic.": + "Aqui está um exemplo de prova de 2+2=4 mostrando várias técnicas.\n\n§0\n\nExtra opcional: você pode rodar essa prova você mesmo. Mude o jogo para o \"Modo editor\" clicando\nno botão §1 no canto superior direito. Agora você pode ver sua prova\nescrita como várias linhas de código. Mova o cursor entre as linhas para ver\no estado do objetivo em qualquer ponto. Agora recorte e cole seu código em outro lugar se\nquiser salvá-lo, e cole a prova acima no lugar. Mova o cursor\npara investigar. Quando terminar, clique no botão §2 no canto superior direito para\nvoltar ao \"Modo máquina de escrever\".\n\nVocê terminou o mundo tutorial!\nClique em \"Leave World\" para voltar ao\nmapa geral, e selecione o Mundo da Adição, onde você vai aprender\nsobre a tática §3.", + "Having to rearrange variables manually using commutativity and\nassociativity is very tedious. We start by reminding you of this. §0\nis a key component in the first algorithm which we'll explain, but we need\nto prove it manually.\n\nRemember that you can do precision commutativity rewriting\nwith things like §1. And remember that\n§2 means §3.": + "Ter que rearranjar variáveis manualmente usando comutatividade e\nassociatividade é bem tedioso. Começamos te lembrando disso. §0\né uma peça-chave no primeiro algoritmo que vamos explicar, mas precisamos\nprová-lo manualmente.\n\nLembre que você pode fazer reescrita de comutatividade com precisão\ncom coisas como §1. E lembre que\n§2 significa §3.", + "Good luck!\n\n One last hint. If §0 then §1 will change *all* §2s into §3s.\n If you only want to change one of them, say the 3rd one, then use\n §4.": + "Boa sorte!\n\n Uma última dica. Se §0, então §1 vai mudar *todos* os §2 em §3.\n Se você quiser mudar apenas um deles, digamos o terceiro, use\n §4.", + "For any natural number §0, we have §1.": + "Para qualquer número natural §0, temos §1.", + "For all numbers §0, §1.": "Para qualquer números §0, §1.", + "For all numbers §0 and §1, we have\n§2": + "Para quaisquer números §0 e §1, temos\n§2", + "For all naturals §0, §1.": "Para quaisquer naturais §0, §1.", + "For all naturals §0, §1, §2, we have §3.": + "Para quaisquer naturais §0, §1, §2, temos §3.", + "For all naturals §0 §1 §2 and §3, we have\n§4": + "Para quaisquer naturais §0 §1 §2 e §3, temos\n§4", + "For all natural numbers §0, we have §1.": + "Para todo número natural §0, temos §1.", + "For all natural numbers §0, we have\n§1.": + "Para quaisquer números naturais §0, temos\r\n§1.", + "For all natural numbers §0 and §1, we have\n§2.": + "Para quaisquer números naturais §0 e §1, temos\n§2.", + "First execute §0 to replace the §1 with §2.": + "Primeiro execute §0 para substituir §1 por §2.", + "Finally use a targetted §0 to switch §1 and §2": + "Por fim, use um §0 direcionado para trocar §1 e §2", + "Fermat's Last Theorem": "Último Teorema de Fermat", + "Every number in Lean is either §0 or a successor. We know how to add §1,\nbut we need to figure out how to add successors. Let's say we already know\nthat §2. What should the answer to §3 be? Well,\n§4 is one bigger than §5, so §6 should be §7,\nthe number one bigger than §8. More generally §9 should\nbe §10. Let's add this as a lemma.\n\n* §11\n\nIf you ever see §12 in your goal, §13 is\nnormally a good idea.\n\nLet's now prove that §14. Figure out how to get §15 into\nthe picture, and then §16. Switch between the §17 (addition) and\n§18 (numerals) tabs under \"Theorems\" on the right to\nsee which proofs you can rewrite.": + "Todo número em Lean é §0 ou um sucessor. Sabemos como somar §1,\nmas precisamos descobrir como somar sucessores. Digamos que já sabemos\nque §2. Qual deveria ser a resposta de §3? Bem,\n§4 é um a mais que §5, então §6 deveria ser §7,\no número um a mais que §8. De forma geral, §9 deveria\nser §10. Vamos adicionar isso como um lema.\n\n* §11\n\nSempre que você vir §12 no seu objetivo, §13 costuma\nser uma boa ideia.\n\nAgora vamos provar que §14. Descubra como colocar §15 em\ncena, e então faça §16. Alterne entre as abas §17 (adição) e\n§18 (numerais) em \"Theorems\" à direita para\nver quais provas você pode reescrever.", + "Do that again!\n\n§0 tries to fill in\nthe arguments to §1 (finding §2) then it replaces all occurrences of\n§3 it finds. Therefor, it did not rewrite §4, yet.": + "Faça isso de novo!\n\n§0 tenta preencher\nos argumentos de §1 (encontrando §2) e então substitui todas as ocorrências de\n§3 que encontrar. Portanto, ele ainda não reescreveu §4.", + "Did you use induction on §0?\nHere's a two-line proof of §1 which uses §2.\nIf you want to inspect it, you can go into editor mode by clicking §3 in the top right\nand then just cut and paste the proof and move your cursor around it\nto see the hypotheses and goal at any given point\n(although you'll lose your own proof this way). Click §4 to get\nback to command line mode.\n§5": + "Você usou indução em §0?\nAqui está uma prova de duas linhas de §1 que usa §2.\nSe quiser inspecioná-la, você pode entrar no modo editor clicando em §3 no canto superior direito\ne depois só copiar e colar a prova e mover o cursor por ela\npara ver as hipóteses e o objetivo em cada ponto\n(embora você perca a sua própria prova assim). Clique em §4 para\nvoltar ao modo linha de comando.\n§5", + "Dealing with §0": "Lidando com §0", + "Congratulations! You've finished Algorithm World. These algorithms\nwill be helpful for you in Even-Odd World (when someone gets around to\nimplementing it).": + "Parabéns! Você terminou o Mundo do Algoritmo. Esses algoritmos\nvão te ajudar no Mundo dos Pares e Ímpares (quando alguém finalmente\nimplementá-lo).", + "Congratulations! You have proved Fermat's Last Theorem!\n\nEither that, or you used magic...": + "Parabéns! Você provou o Último Teorema de Fermat!\n\nOu isso, ou você usou magia...", + "Congratulations! You completed your first verified proof!\n\nRemember that §0 is a *tactic*. If you ever want information about the §1 tactic,\nyou can click on §2 in the list of tactics on the right.\n\nNow click on \"Next\" to learn about the §3 tactic.": + "Parabéns! Você completou sua primeira prova verificada!\n\nLembre-se de que §0 é uma *tática*. Se algum dia você quiser informações sobre a tática §1,\npode clicar em §2 na lista de táticas à direita.\n\nAgora clique em \"Próximo\" para aprender sobre a tática §3.", + "Concretely: §0.": "Concretamente: §0.", + "Can you take it from here? Click on \"Show more help!\" if you need a hint.": + "Consegue seguir daqui? Clique em \"Mostrar mais ajuda!\" se precisar de uma dica.", + "Can you take it from here? (note: if you try §0 again, it will\ntake you back to where you started!)": + "Consegue seguir daqui? (nota: se você tentar §0 de novo, ele vai\nte levar de volta para onde você começou!)", + "Can you take it from here?": "Consegue continuar daqui?", + "Can you now change the goal into §0?": + "Agora você consegue transformar o objetivo em §0?", + "At this point you see the term §0, so you can use the\ninduction hypothesis with §1.": + "Neste ponto você vê o termo §0, então pode usar a\nhipótese de indução com §1.", + "Assuming §0, we have §1.": "Supondo que §0, temos §1.", + "Assuming §0 and §1, we have §2.": "Supondo §0 e §1, temos §2.", + "As warm-up for §0 let's prove §1. To do this we need to\nintroduce Peano's last axiom §2, a proof that §3.\nTo learn about this result, click on it in the list of lemmas on the right.": + "Como aquecimento para §0, vamos provar §1. Para isso precisamos\nintroduzir o último axioma de Peano, §2, uma prova de que §3.\nPara aprender sobre esse resultado, clique nele na lista de lemas à direita.", + "Arguing backwards": "Argumentando de trás para frente", + "Applying a proof of §0 to the *goal* changes §1 to §2.\nNow try §3 to make the goal more like the hypothesis.": + "Aplicar uma prova de §0 ao *objetivo* transforma §1 em §2.\nAgora tente fazer §3 para deixar o objetivo mais parecido com a hipótese.", + "And now §0": "E agora §0", + "And now we've deduced what we wanted to prove: the goal is one of our assumptions.\nFinish the level with §0.": + "E agora deduzimos o que queríamos provar: o objetivo é uma das nossas hipóteses.\nTermine o nível com §0.", + "And finally §0.": "E finalmente §0.", + "An algorithm for equality": "Um algoritmo para igualdade", + "Although §0 in this game, §1 if §2, i.e., if\n§3 is a successor.": + "Embora §0 neste jogo, §1 se §2, ou seja, se\n§3 for um sucessor.", + "Algorithm World": "Mundo do Algoritmo", + "Advanced Multiplication World": "Mundo da Multiplicação Avançada", + "Advanced Addition World": "Mundo da Adição Avançada", + "Advanced *Addition* World proved various implications\ninvolving addition, such as §0 and §1.\nThese lemmas were used to prove basic facts about ≤ in ≤ World.\n\nIn Advanced Multiplication World we prove analogous\nfacts about multiplication, such as §2, and\n§3 (assuming §4 in the latter result). This will prepare\nus for Divisibility World.\n\nMultiplication World is more complex than Addition World. In the same\nway, Advanced Multiplication world is more complex than Advanced Addition\nWorld. One reason for this is that certain intermediate results are only\ntrue under the additional hypothesis that one of the variables is non-zero.\nThis causes some unexpected extra twists.": + "No Mundo da *Adição* Avançada provamos várias implicações\nenvolvendo adição, como §0 e §1.\nEsses lemas foram usados para provar fatos básicos sobre ≤ no Mundo do ≤.\n\nNo Mundo da Multiplicação Avançada provamos fatos análogos\nsobre multiplicação, como §2 e\n§3 (supondo §4 neste último resultado). Isso vai nos preparar\npara o Mundo da Divisibilidade.\n\nO Mundo da Multiplicação é mais complexo que o Mundo da Adição. Do mesmo\njeito, o Mundo da Multiplicação Avançada é mais complexo que o Mundo da Adição\nAvançada. Uma razão para isso é que certos resultados intermediários só\nsão verdadeiros sob a hipótese adicional de que uma das variáveis é não nula.\nIsso causa algumas reviravoltas inesperadas.", + "Addition is distributive over multiplication.\nIn other words, for all natural numbers §0, §1 and §2, we have\n§3.": + "A adição é distributiva sobre a multiplicação.\nEm outras palavras, para quaisquer números naturais §0, §1 e §2, temos\n§3.", + "Addition World": "Mundo da Adição", + "Adding zero": "Somando zero", + "A two-line proof is\n\n§0\n\nWe now have all the tools necessary to set up the basic theory of divisibility of naturals.": + "Uma prova de duas linhas é\n\n§0\n\nAgora temos todas as ferramentas necessárias para montar a teoria básica da divisibilidade dos naturais.", + "A proof that §0.": "Uma prova de que §0.", + "A passing mathematician remarks that with reflexivity and transitivity out of the way,\nyou have proved that §0 is a *preorder* on §1.": + "Um matemático que passava por ali comenta que, com a reflexividade e a transitividade resolvidas,\nvocê provou que §0 é uma *pré-ordem* em §1.", + "A passing mathematician notes that you've proved\nthat the natural numbers are a commutative semiring.\n\nIf you want to begin your journey to the final boss, head for Power World.": + "Um matemático que passava por aqui observa que você provou\nque os números naturais formam um semianel comutativo.\n\nSe quiser começar sua jornada rumo ao chefão final, vá para o Mundo da Potência.", + "A passing mathematician congratulates you on proving that naturals\nare an additive commutative monoid.\n\nLet's practice using §0 and §1 in one more level,\nbefore we leave addition world.": + "Um matemático que passava por aqui te parabeniza por provar que os naturais\nformam um monoide comutativo aditivo.\n\nVamos praticar o uso de §0 e §1 em mais um nível,\nantes de deixarmos o mundo da adição.", + "2+2=4": "2+2=4", + "2 + 2 ≠ 5 is boring to prove in full, given only the tools we have currently.\nTo make it a bit less painful, I have unfolded all of the numerals for you.\nSee if you can use §0 and §1 to prove this.": + "2 + 2 ≠ 5 é chato de provar por completo, dadas apenas as ferramentas que temos no momento.\nPara deixar isso um pouco menos doloroso, eu já desdobrei todos os numerais para você.\nVeja se você consegue usar §0 e §1 para provar isso.", + "2 + 2 ≠ 5": "2 + 2 ≠ 5", + "1 ≠ 0": "1 ≠ 0", + "0 ≤ x": "0 ≤ x", + "*Game version: 4.3*\n\n*Recent additions: bug fixes*\n\n## Progress saving\n\nThe game stores your progress in your local browser storage.\nIf you delete it, your progress will be lost!\n\nWarning: In most browsers, deleting cookies will also clear the local storage\n(or \"local site data\"). Make sure to download your game progress first!\n\n## Credits\n\n* **Creators:** Kevin Buzzard, Jon Eugster\n* **Original Lean3-version:** Kevin Buzzard, Mohammad Pedramfar\n* **Game Engine:** Alexander Bentkamp, Jon Eugster, Patrick Massot\n* **Additional levels:** Sian Carey, Ivan Farabella, Archie Browne.\n* **Additional thanks:** All the student beta testers, all the schools\nwho invited Kevin to speak, and all the schoolkids who asked him questions\nabout the material.\n\n## Resources\n\n* The [Lean Zulip chat](https://leanprover.zulipchat.com/) forum\n* [Original Lean3 version](https://www.ma.imperial.ac.uk/~buzzard/xena/natural_number_game/) (no longer maintained)\n\n## Problems?\n\nPlease ask any questions about this game in the\n[Lean Zulip chat](https://leanprover.zulipchat.com/) forum, for example in\nthe stream \"New Members\". The community will happily help. Note that\nthe Lean Zulip chat is a professional research forum.\nPlease use your full real name there, stay on topic, and be nice. If you're\nlooking for somewhere less formal (e.g. you want to post natural number\ngame memes) then head on over to the [Lean Discord](https://discord.gg/WZ9bs9UCvx).\n\nAlternatively, if you experience issues / bugs you can also open github issues:\n\n* For issues with the game engine, please open an\n[issue at the lean4game](https://github.com/leanprover-community/lean4game/issues) repo.\n* For issues about the game's content, please open an\n[issue at the NNG](https://github.com/hhu-adam/NNG4/issues) repo.": + "*Versão do jogo: 4.3*\n\n*Adições recentes: correções de bugs*\n\n## Salvamento do progresso\n\nO jogo guarda seu progresso no armazenamento local do seu navegador.\nSe você apagá-lo, seu progresso será perdido!\n\nAtenção: na maioria dos navegadores, apagar os cookies também limpa o armazenamento local\n(ou \"dados locais do site\"). Certifique-se de baixar seu progresso antes!\n\n## Créditos\n\n* **Criadores:** Kevin Buzzard, Jon Eugster\n* **Versão original em Lean3:** Kevin Buzzard, Mohammad Pedramfar\n* **Engine do jogo:** Alexander Bentkamp, Jon Eugster, Patrick Massot\n* **Níveis adicionais:** Sian Carey, Ivan Farabella, Archie Browne.\n* **Tradução para Português Brasileiro:** Luís Felipe Marques.\n* **Agradecimentos adicionais:** Todos os estudantes beta testers, todas as escolas\nque convidaram Kevin para palestrar, e todos os alunos que lhe fizeram perguntas\nsobre o material.\n\n## Recursos\n\n* O fórum [Lean Zulip chat](https://leanprover.zulipchat.com/)\n* [Versão original em Lean3](https://www.ma.imperial.ac.uk/~buzzard/xena/natural_number_game/) (não mantida mais)\n\n## Problemas?\n\nPor favor, faça qualquer pergunta sobre este jogo no fórum\n[Lean Zulip chat](https://leanprover.zulipchat.com/), por exemplo no\ncanal \"New Members\". A comunidade vai ajudar com prazer. Note que\no Lean Zulip chat é um fórum profissional de pesquisa.\nPor favor, use seu nome real completo lá, mantenha-se no tema e seja gentil. Se você\nprocura algo menos formal (por exemplo, se quiser postar memes do jogo dos números\nnaturais), então vá para o [Discord do Lean](https://discord.gg/WZ9bs9UCvx).\n\nAlternativamente, se você encontrar problemas / bugs, também pode abrir issues no github:\n\n* Para problemas com o motor do jogo, por favor abra uma\n[issue no repositório do lean4game](https://github.com/leanprover-community/lean4game/issues).\n* Para problemas com o conteúdo do jogo, por favor abra uma\n[issue no repositório do NNG](https://github.com/hhu-adam/NNG4/issues).", + "## The birth of number.\n\nNumbers in Lean are defined by two rules.\n\n* §0 is a number.\n* If §1 is a number, then the *successor* §2 of §3 is a number.\n\nThe successor of §4 means the number after §5. Let's learn to\ncount, and name a few small numbers.\n\n## Counting to four.\n\n§6 is a number, so §7 is a number. Let's call this new number §8.\nSimilarly let's define §9, §10 and §11.\nThis gives us plenty of numbers to be getting along with.\n\nThe *proof* that §12 is called §13.\nCheck out the \"012\" tab in the list of lemmas on the right\nfor this and other proofs.\n\nLet's prove that §14 is the number after the number after zero.": + "## O nascimento do número.\n\nOs números em Lean são definidos por duas regras.\n\n* §0 é um número.\n* Se §1 é um número, então o *sucessor* §2 de §3 é um número.\n\nO sucessor de §4 significa o número depois de §5. Vamos aprender a\ncontar e dar nome a alguns números pequenos.\n\n## Contando até quatro.\n\n§6 é um número, então §7 é um número. Vamos chamar esse novo número de §8.\nDo mesmo jeito, vamos definir §9, §10 e §11.\nIsso já nos dá bastante números para trabalhar.\n\nA *prova* de que §12 se chama §13.\nDê uma olhada na aba \"012\" na lista de lemas à direita\npara ver essa e outras provas.\n\nVamos provar que §14 é o número depois do número depois do zero.", + "## Summary\n\n§0 repeatedly applies the tactic §1\nto the goal. You don't need to use this\ntactic, it just speeds things up sometimes.\n\n## Example\n\n§2 will turn the goal\n§3\ninto the goal\n§4.\n\"\n\nTacticDoc nth_rewrite \"\n## Summary\n\nIf §5 and there are several §6s in the goal, then\n§7 will just change the third §8 to a §9.\n\n## Example\n\nIf the goal is §10 then §11\nwill change the goal to §12. In contrast, §13\nwill change the goal to §14.": + "## Resumo\n\n§0 aplica repetidamente a tática §1\nao objetivo. Você não precisa usar essa\ntática, ela só acelera as coisas às vezes.\n\n## Exemplo\n\n§2 vai transformar o objetivo\n§3\nno objetivo\n§4.\n\"\n\nTacticDoc nth_rewrite \"\n## Resumo\n\nSe §5 e há vários §6s no objetivo, então\n§7 vai mudar apenas o terceiro §8 para um §9.\n\n## Exemplo\n\nSe o objetivo é §10 então §11\nvai mudar o objetivo para §12. Em contraste, §13\nvai mudar o objetivo para §14.", + "## Summary\n\n§0 repeatedly applies the tactic §1\nto the goal. You don't need to use this\ntactic, it just speeds things up sometimes.\n\n## Example\n\n§2 will turn the goal\n§3\ninto the goal\n§4.": + "## Resumo\n\n§0 aplica repetidamente a tática §1\nao objetivo. Você não precisa usar essa\ntática, ela só acelera as coisas às vezes.\n\n## Exemplo\n\n§2 transforma o objetivo\n§3\nno objetivo\n§4.", + "## Summary\n\n§0 proves goals of the form §1.\n\nIn other words, the §2 tactic will close any goal of the\nform §3 if §4 and §5 are *identical*.\n\n§6 is short for \\\\\"reflexivity (of equality)\\\\\".\n\n## Example:\n\nIf the goal looks like this:\n\n§7\n\nthen §8 will close it. But if it looks like §9 then §10 won't work, because even\nthough §11 and §12 are always equal as *numbers*, they are not equal as *terms*.\nThe only term which is identical to §13 is §14.\n\n## Details\n\n§15 is short for \\\\\"reflexivity of equality\\\\\".\n\n## Game Implementation\n\n*Note that our §16 is weaker than the version used in core Lean and §17,\nfor pedagogical purposes; mathematicians do not distinguish between propositional\nand definitional equality because they think about definitions in a different way\nto type theorists (§18 and §19 are both \\\\\"facts\\\\\" as far\nas mathematicians are concerned, and who cares what the definition of addition is).*": + "## Resumo\n\n§0 prova objetivos da forma §1.\n\nEm outras palavras, a tática §2 fecha qualquer objetivo da\nforma §3 se §4 e §5 forem *idênticos*.\n\n§6 é abreviação de \\\"reflexividade (da igualdade)\\\".\n\n## Exemplo:\n\nSe o objetivo for assim:\n\n§7\n\nentão §8 vai fechá-lo. Mas se for §9 então §10 não vai funcionar, pois mesmo\nque §11 e §12 sejam sempre iguais como *números*, eles não são iguais como *termos*.\nO único termo idêntico a §13 é §14.\n\n## Detalhes\n\n§15 é abreviação de \\\"reflexividade da igualdade\\\".\n\n## Implementação no jogo\n\n*Note que nosso §16 é mais fraco que a versão usada no núcleo do Lean e na §17,\npor motivos pedagógicos; matemáticos não distinguem entre igualdade proposicional\ne definicional porque pensam sobre definições de um jeito diferente dos\nteóricos de tipos (§18 e §19 são ambos \\\"fatos\\\" no que diz respeito\naos matemáticos, e quem se importa com qual é a definição de adição).*", + "## Summary\n\nThe §0 tactic will change a goal or hypothesis of\nthe form §1 to §2. It will also work on §3\nand on §4.\n\n### Example\n\nIf the goal is §5 then §6 will change it to §7.\n\n### Example\n\nIf §8 then §9 will change §10 to §11.": + "## Resumo\n\nA tática §0 transforma um objetivo ou uma hipótese da\nforma §1 em §2. Ela também funciona com §3\ne com §4.\n\n### Exemplo\n\nSe o objetivo é §5, então §6 vai mudá-lo para §7.\n\n### Exemplo\n\nSe §8, então §9 vai mudar §10 para §11.", + "## Summary\n\nThe §0 tactic makes progress with goals which claim something *exists*.\nIf the goal claims that some §1 exists with some property, and you know\nthat §2 will work, then §3 will make progress.\n\nBecause §4 is notation for \\\\\"there exists §5 such that §6\\\\\",\nyou can make progress on goals of the form §7 by §8ing the\nnumber which is morally §9 (i.e. §10)\n\nAny of the following examples is possible assuming the type of the argument passed to the §11 function is accurate:\n\n- §12\n- §13\n- §14": + "## Resumo\n\nA tática §0 faz progresso em objetivos que afirmam que algo *existe*.\nSe o objetivo afirma que existe algum §1 com alguma propriedade, e você sabe\nque §2 vai funcionar, então §3 faz progresso.\n\nComo §4 é notação para \\\\\"existe §5 tal que §6\\\\\",\nvocê pode fazer progresso em objetivos da forma §7 aplicando §8 ao\nnúmero que moralmente é §9 (ou seja, §10)\n\nQualquer um dos exemplos a seguir é possível, desde que o tipo do argumento passado para a função §11 esteja correto:\n\n- §12\n- §13\n- §14", + "## Summary\n\nIf §0 is an object, and the goal mentions §1, then §2\nattempts to prove the goal by induction on §3, with the inductive\nvariable in the successor case being §4, and the inductive hypothesis being §5.\n\n### Example:\nIf the goal is\n§6\n\nthen\n\n§7\n\nwill turn it into two goals. The first is §8;\nthe second has an assumption §9 and goal\n§10.\n\nNote that you must prove the first\ngoal before you can access the second one.": + "## Resumo\n\nSe §0 é um objeto, e o objetivo menciona §1, então §2\ntenta provar o objetivo por indução em §3, sendo a variável indutiva\nno caso do sucessor §4, e a hipótese indutiva §5.\n\n### Exemplo:\nSe o objetivo é\n§6\n\nentão\n\n§7\n\nvai transformá-lo em dois objetivos. O primeiro é §8;\no segundo tem uma hipótese §9 e objetivo\n§10.\n\nNote que você precisa provar o primeiro\nobjetivo antes de poder acessar o segundo.", + "## Summary\n\nIf §0 is a proof that §1, and §2 is a proof of §3,\nthen §4 will change §5 to a proof of §6. The idea is that if\nyou know §7 is true, then you can deduce from §8 that §9 is true.\n\nIf the *goal* is §10, then §11 will \\\\\"argue backwards\\\\\" and change the\ngoal to §12. The idea here is that if you want to prove §13, then by §14\nit suffices to prove §15, so you can reduce the goal to proving §16.\n\n### Example:\n\n§17 is a proof that §18.\n\nSo if you have a hypothesis §19\nthen §20 will change §21 to §22.\nYou could write §23\nbut Lean is smart enough to figure out the inputs to §24.\n\n### Example\n\nIf the goal is §25, then §26 will turn the\ngoal into §27.": + "## Resumo\n\nSe §0 é uma prova de que §1, e §2 é uma prova de §3,\nentão §4 vai transformar §5 numa prova de §6. A ideia é que, se\nvocê sabe que §7 é verdadeiro, então pode deduzir de §8 que §9 é verdadeiro.\n\nSe o *objetivo* for §10, então §11 vai \\\\\"argumentar de trás para frente\\\\\" e mudar o\nobjetivo para §12. A ideia aqui é que, se você quer provar §13, então por §14\nbasta provar §15, de modo que você pode reduzir o objetivo a provar §16.\n\n### Exemplo:\n\n§17 é uma prova de que §18.\n\nEntão, se você tem uma hipótese §19,\n§20 vai mudar §21 para §22.\nVocê poderia escrever §23,\nmas Lean é esperto o bastante para descobrir sozinho as entradas de §24.\n\n### Exemplo\n\nSe o objetivo é §25, então §26 vai transformar o\nobjetivo em §27.", + "## Summary\n\nIf §0 is a proof of an equality §1, then §2 will change\nall §3s in the goal to §4s. It's the way to \\\\\"substitute in\\\\\".\n\n## Variants\n\n* §5 (changes §6s to §7s; get the back arrow by typing §8 or §9.)\n\n* §10 (a sequence of rewrites)\n\n* §11 (changes §12s to §13s in hypothesis §14)\n\n* §15 (changes §16s to §17s in two hypotheses and the goal;\nget the §18 symbol with §19.)\n\n* §20 will keep changing §21 to §22\nuntil there are no more matches for §23.\n\n* §24 will change only the second §25 in the goal to §26.\n\n### Example:\n\nIf you have the assumption §27 and your goal is\n§28\n\nthen\n\n§29\n\nwill change the goal into §30, and then\n\n§31\n\nwill change the goal into §32, which\ncan be solved with §33.\n\n### Example:\n\nYou can use §34 to change a hypothesis as well.\nFor example, if you have two hypotheses\n§35\nthen §36 will turn §37 into §38.\n\n## Common errors\n\n* You need the square brackets. §39 is never correct.\n\n* If §40 is not a *proof* of an *equality* (a statement of the form §41),\nfor example if §42 is a function or an implication,\nthen §43 is not the tactic you want to use. For example,\n§44 is never correct: §45 is the theorem *statement*,\nnot the proof. If §46 is the proof, then §47 will work.\n\n## Details\n\nThe §48 tactic is a way to do \\\\\"substituting in\\\\\". There\nare two distinct situations where you can use this tactic.\n\n1) Basic usage: if §49 is an assumption or\nthe proof of a theorem, and if the goal contains one or more §50s, then §51\nwill change them all to §52s. The tactic will error\nif there are no §53s in the goal.\n\n2) Advanced usage: Assumptions coming from theorem proofs\noften have missing pieces. For example §54\nis a proof that §55 because §56 really is a function,\nand §57 is the input. In this situation §58 will look through the goal\nfor any subterm of the form §59, and the moment it\nfinds one it fixes §60 to be §61 then changes all §62s to §63s.\n\nExercise: think about why §64 changes the term\n§65 to\n§66\n\nIf you can't remember the name of the proof of an equality, look it up in\nthe list of lemmas on the right.\n\n## Targetted usage\n\nIf your goal is §67 and you want to rewrite §68\nto §69, then §70 will not work because Lean finds another\naddition first and swaps those inputs instead. Use §71 to\nguarantee that Lean rewrites §72 to §73. This works because\n§74 is a proof that §75, §76 is a proof\nthat §77, and §78 is a proof that §79.\n\nIf §80 then §81 will turn all §82s into §83s.\nIf you only want to change the 37th occurrence of §84\nto §85 then do §86.": + "## Resumo\n\nSe §0 é uma prova de uma igualdade §1, então §2 vai trocar\ntodos os §3 do objetivo por §4. É o jeito de \\\\\"substituir\\\\\".\n\n## Variantes\n\n* §5 (troca §6 por §7; obtenha a seta para trás digitando §8 ou §9.)\n\n* §10 (uma sequência de reescritas)\n\n* §11 (troca §12 por §13 na hipótese §14)\n\n* §15 (troca §16 por §17 em duas hipóteses e no objetivo;\nconsiga o símbolo §18 com §19.)\n\n* §20 vai continuar trocando §21 por §22\naté não haver mais ocorrências de §23.\n\n* §24 vai trocar por §26 apenas o segundo §25 do objetivo.\n\n### Exemplo:\n\nSe você tem a hipótese §27 e o seu objetivo é\n§28\n\nentão\n\n§29\n\nvai mudar o objetivo para §30, e depois\n\n§31\n\nvai mudar o objetivo para §32, que\npode ser resolvido com §33.\n\n### Exemplo:\n\nVocê também pode usar §34 para mudar uma hipótese.\nPor exemplo, se você tem duas hipóteses\n§35\nentão §36 vai transformar §37 em §38.\n\n## Erros comuns\n\n* Você precisa dos colchetes. §39 nunca está correto.\n\n* Se §40 não é uma *prova* de uma *igualdade* (um enunciado da forma §41),\npor exemplo se §42 é uma função ou uma implicação,\nentão §43 não é a tática que você quer usar. Por exemplo,\n§44 nunca está correto: §45 é o *enunciado* do teorema,\nnão a prova. Se §46 é a prova, então §47 vai funcionar.\n\n## Detalhes\n\nA tática §48 é um jeito de \\\\\"substituir\\\\\". Existem\nduas situações distintas em que você pode usar essa tática.\n\n1) Uso básico: se §49 é uma hipótese ou\na prova de um teorema, e se o objetivo contém um ou mais §50, então §51\nvai trocar todos eles por §52. A tática dá erro\nse não houver nenhum §53 no objetivo.\n\n2) Uso avançado: hipóteses vindas de provas de teoremas\nmuitas vezes têm partes faltando. Por exemplo, §54\né uma prova de que §55 porque §56 é na verdade uma função,\ne §57 é a entrada. Nessa situação, §58 vai procurar no objetivo\nqualquer subtermo da forma §59, e no momento em que\nencontra um ele fixa §60 como §61 e então troca todos os §62 por §63.\n\nExercício: pense em por que §64 muda o termo\n§65 para\n§66\n\nSe você não lembrar o nome da prova de uma igualdade, procure\nna lista de lemas à direita.\n\n## Uso direcionado\n\nSe o seu objetivo é §67 e você quer reescrever §68\ncomo §69, então §70 não vai funcionar porque o Lean encontra outra\nadição primeiro e troca as entradas dela. Use §71 para\ngarantir que o Lean reescreva §72 como §73. Isso funciona porque\n§74 é uma prova de que §75, §76 é uma prova\nde que §77, e §78 é uma prova de que §79.\n\nSe §80 então §81 vai transformar todos os §82 em §83.\nSe você só quer mudar a 37ª ocorrência de §84\npara §85, então faça §86.", + "## Summary\n\nIf §0 is a number, then §1 will break the goal into two goals,\none with §2 and the other with §3.\n\nIf §4 is a proof (for example a hypothesis), then §5 will break the\nproof up into the pieces used to prove it.\n\n## Example\n\nIf §6 is a number, then §7 will break the goal into two goals,\none with §8 replaced by 0 and the other with §9 replaced by §10. This\ncorresponds to the mathematical idea that every natural number is either §11\nor a successor.\n\n## Example\n\nIf §12 is a hypothesis, then §13 will turn one goal\ninto two goals, one with a hypothesis §14 and the other with a\nhypothesis §15.\n\n## Example\n\nIf §16 is a hypothesis, then §17 will turn one goal into no goals,\nbecause there are no ways to make a proof of §18! And if you have no goals left,\nyou have finished the level.\n\n## Example\n\nIf §19 is a hypothesis, then §20 will create a new number §21\nand a proof §22. This is because the *definition* of §23 is\n§24.": + "## Resumo\n\nSe §0 é um número, então §1 vai quebrar o objetivo em dois objetivos,\num com §2 e o outro com §3.\n\nSe §4 é uma prova (por exemplo, uma hipótese), então §5 vai quebrar a\nprova nos pedaços usados para prová-la.\n\n## Exemplo\n\nSe §6 é um número, então §7 vai quebrar o objetivo em dois objetivos,\num com §8 substituído por 0 e o outro com §9 substituído por §10. Isso\ncorresponde à ideia matemática de que todo número natural é §11\nou um sucessor.\n\n## Exemplo\n\nSe §12 é uma hipótese, então §13 vai transformar um objetivo\nem dois objetivos, um com uma hipótese §14 e o outro com uma\nhipótese §15.\n\n## Exemplo\n\nSe §16 é uma hipótese, então §17 vai transformar um objetivo em nenhum objetivo,\nporque não há jeito nenhum de construir uma prova de §18! E se você não tem mais objetivos,\nvocê terminou o nível.\n\n## Exemplo\n\nSe §19 é uma hipótese, então §20 vai criar um novo número §21\ne uma prova §22. Isso porque a *definição* de §23 é\n§24.", + "## Summary\n\nIf §0 and there are several §1s in the goal, then\n§2 will just change the third §3 to a §4.\n\n## Example\n\nIf the goal is §5 then §6\nwill change the goal to §7. In contrast, §8\nwill change the goal to §9.": + "## Resumo\n\nSe §0 e há vários §1 no objetivo, então\n§2 vai mudar apenas o terceiro §3 para §4.\n\n## Exemplo\n\nSe o objetivo é §5 então §6\nvai mudar o objetivo para §7. Em contraste, §8\nvai mudar o objetivo para §9.", + "## Summary\n\nIf the goal is §0, then §1 will introduce §2 as a hypothesis,\nand change the goal to §3. Mathematically, it says that to prove §4,\nwe can assume §5 and then prove §6.\n\n### Example:\n\nIf your goal is §7 (the way Lean writes §8)\nthen §9 will give you a hypothesis §10 named §11, and the goal\nwill change to §12.": + "## Resumo\n\nSe o objetivo é §0, então §1 vai introduzir §2 como hipótese,\ne mudar o objetivo para §3. Matematicamente, isso diz que para provar §4,\npodemos supor §5 e então provar §6.\n\n### Exemplo:\n\nSe o seu objetivo é §7 (o jeito que Lean escreve §8)\nentão §9 vai te dar uma hipótese §10 chamada §11, e o objetivo\nvai mudar para §12.", + "## Summary\n\nIf the goal is a statement §0, then §1 will close the goal if §2 is a proof of §3.\n\n### Example\n\nIf the goal is §4 and you have a hypothesis §5\nthen §6 will solve the goal.\n\n### Example\n\nIf the goal is §7 then §8 will close the goal.\n\n### Exact needs to be exactly right\n\nNote that §9 will *not work* in the previous example;\nfor §10 to work, §11 has to be *exactly* a proof of the goal.\n§12 is a proof of §13 or, if you like,\na proof of §14 where §15 needs to be supplied by the user.\nThis is in contrast to §16 and §17, which will \\\\\"guess the inputs\\\\\"\nif necessary. If the goal is §18 then §19\nand §20 will both change the goal to §21,\nbecause §22 guesses the input to the function §23.": + "## Resumo\n\nSe o objetivo é um enunciado §0, então §1 fecha o objetivo se §2 for uma prova de §3.\n\n### Exemplo\n\nSe o objetivo é §4 e você tem uma hipótese §5\nentão §6 resolve o objetivo.\n\n### Exemplo\n\nSe o objetivo é §7 então §8 fecha o objetivo.\n\n### Exact precisa ser exatamente certo\n\nNote que §9 *não funciona* no exemplo anterior;\npara §10 funcionar, §11 tem que ser *exatamente* uma prova do objetivo.\n§12 é uma prova de §13 ou, se preferir,\numa prova de §14 onde §15 precisa ser fornecido pelo usuário.\nIsso contrasta com §16 e §17, que vão \\\\\"adivinhar as entradas\\\\\"\nse necessário. Se o objetivo é §18 então §19\ne §20 vão ambos mudar o objetivo para §21,\nporque §22 adivinha a entrada da função §23.", + "## Precision rewriting\n\nIn the last level, there was §0 and §1,\nand §2 changed the first one it saw,\nwhich was §3. Let's learn how to tell Lean\nto change §4 first by giving §5 an\nexplicit input.": + "## Reescrita com precisão\n\nNo nível anterior, havia §0 e §1,\ne §2 mudou o primeiro que encontrou,\nque era §3. Vamos aprender a dizer ao Lean\npara mudar §4 primeiro, dando a §5 uma\nentrada explícita.", + "# Welcome to the Natural Number Game\n#### An introduction to mathematical proof.\n\nIn this game, we will build the basic theory of the natural\nnumbers §0 from scratch. Our first goal is to prove\nthat §1. Next we'll prove that §2.\nAnd at the end we'll see if we can prove Fermat's Last Theorem.\nWe'll do this by solving levels of a computer puzzle game called Lean.\n\n# Read this.\n\nLearning how to use an interactive theorem prover takes time.\nTests show that the people who get the most out of this game are\nthose who read the help texts like this one.\n\nTo start, click on \"Tutorial World\".\n\nNote: this is a new Lean 4 version of the game containing several\nworlds which were not present in the old Lean 3 version. More new worlds\nsuch as Strong Induction World, Even/Odd World and Prime Number World\nare in development; if you want to see their state or even help out, checkout\nout the [issues in the github repo](https://github.com/leanprover-community/NNG4/issues).\n\n## More\n\nClick on the three lines in the top right and select \"Game Info\" for resources,\nlinks, and ways to interact with the Lean community.": + "# Bem-vindo ao Jogo dos Números Naturais\n#### Uma introdução à prova matemática.\n\nNeste jogo, vamos construir do zero a teoria básica dos números\nnaturais §0. Nosso primeiro objetivo é provar\nque §1. Depois vamos provar que §2.\nE no final vamos ver se conseguimos provar o Último Teorema de Fermat.\nFaremos isso resolvendo níveis de um jogo de quebra-cabeça de computador chamado Lean.\n\n# Leia isto.\n\nAprender a usar um provador de teoremas interativo leva tempo.\nTestes mostram que as pessoas que mais aproveitam este jogo são\naquelas que leem os textos de ajuda como este.\n\nPara começar, clique em \"Mundo Tutorial\".\n\nNota: esta é uma nova versão do jogo em Lean 4, contendo vários\nmundos que não existiam na antiga versão em Lean 3. Novos mundos,\ncomo o Mundo da Indução Forte, o Mundo dos Pares e Ímpares e o Mundo dos Números Primos,\nestão em desenvolvimento; se você quiser ver o estado deles ou até ajudar, dê uma olhada\nnas [issues no repositório do github](https://github.com/leanprover-community/NNG4/issues).\n\n## Mais\n\nClique nas três linhas no canto superior direito e selecione \"Informações do jogo\" para recursos,\nlinks e formas de interagir com a comunidade Lean.", + "# Summary\nThe §0 tactic changes a goal of §1 into a goal of §2.\nUse it when your hypotheses guarantee that the reason that §3\nis true is because in fact §4 is true.\n\nInternally this tactic is just §5ing a theorem\nsaying that §6\n\nNote that this tactic can turn a solvable goal into an unsolvable\none.": + "# Resumo\nA tática §0 transforma um objetivo §1 em um objetivo §2.\nUse-a quando suas hipóteses garantirem que a razão de §3\nser verdadeiro é que, na verdade, §4 é verdadeiro.\n\nInternamente, essa tática apenas faz §5 de um teorema\ndizendo que §6\n\nNote que essa tática pode transformar um objetivo solúvel em um\ninsolúvel.", + "# Summary\n\n§0 will solve the goal §1.": + "# Resumo\n\n§0 resolve o objetivo §1.", + "# Summary\n\n§0 will attempt to solve a goal if it can find an algorithm which it\ncan run to solve it.\n\n## Example\n\nA term of type §1 is an algorithm to decide whether two naturals\nare equal or different. Hence, once this term is made and made into an §2,\nthe §3 tactic can use it to solve goals of the form §4 or §5.": + "# Resumo\n\n§0 vai tentar resolver um objetivo se conseguir encontrar um algoritmo que\npossa executar para resolvê-lo.\n\n## Exemplo\n\nUm termo do tipo §1 é um algoritmo para decidir se dois naturais\nsão iguais ou diferentes. Portanto, uma vez que esse termo seja construído e transformado numa §2,\na tática §3 pode usá-lo para resolver objetivos da forma §4 ou §5.", + "# Summary\n\nThe §0 tactic will solve any goal which can be solved purely by logic (that is, by\ntruth tables).\n\n## Details\n\n§1 *does not do magic*! It doesn't know *anything* about addition or multiplication,\nit doesn't even know §2. The only things that §3 knows about numbers\nare firstly that §4 and secondly that §5, §6, §7 and so on.\nWhat §8's strength is, is *logic*. If you have a hypothesis §9\nand another hypothesis §10 and your goal is §11 then §12 will\nsolve this goal, because to solve that goal you don't need to know any facts\nabout inequalities or addition, all you need to know is the rules of logic.\n\n## Example\n\nIf you have §13 as a hypothesis, then §14 will solve\nthe goal. This is because a false hypothesis implies any hypothesis.\n\n## Example\n\nIf your goal is §15, then §16 will solve the goal.\n\n## Example\n\nIf you have two hypotheses §17 and §18 then §19 will\nsolve the goal because it can prove §20 from your hypotheses, and thus\nprove the goal (as §21 implies anything).\n\n## Example\n\nIf you have one hypothesis §22 then §23 will solve the goal because\n§24 is smart enough to know that §25 is true, which gives the contradiction we seek.\n\n## Example\n\nIf you have a hypothesis §26 then §27 will solve the goal, because\n§28 knows §29 and this is enough to prove §30, which implies any goal.\n\n## Example\n\nIf you have a hypothesis of the form §31 and your goal is §32, then\n§33 will solve the goal, because the goal is logically equivalent to the hypothesis.\nIf you switch the goal and hypothesis in this example, §34 would solve it too.": + "# Resumo\n\nA tática §0 resolve qualquer objetivo que possa ser resolvido puramente por lógica (ou seja, por\ntabelas-verdade).\n\n## Detalhes\n\n§1 *não faz mágica*! Ela não sabe *nada* sobre adição ou multiplicação,\nnem sequer conhece §2. As únicas coisas que §3 sabe sobre números\nsão, primeiro, que §4 e, segundo, que §5, §6, §7 e assim por diante.\nA força de §8 é a *lógica*. Se você tem uma hipótese §9\ne outra hipótese §10 e seu objetivo é §11, então §12 vai\nresolver esse objetivo, porque para resolvê-lo você não precisa saber nenhum fato\nsobre desigualdades ou adição, só precisa conhecer as regras da lógica.\n\n## Exemplo\n\nSe você tem §13 como hipótese, então §14 resolve\no objetivo. Isso porque uma hipótese falsa implica qualquer hipótese.\n\n## Exemplo\n\nSe o seu objetivo é §15, então §16 resolve o objetivo.\n\n## Exemplo\n\nSe você tem duas hipóteses §17 e §18, então §19 vai\nresolver o objetivo, porque ela consegue provar §20 a partir das suas hipóteses, e assim\nprovar o objetivo (já que §21 implica qualquer coisa).\n\n## Exemplo\n\nSe você tem uma hipótese §22, então §23 resolve o objetivo, porque\n§24 é esperta o bastante para saber que §25 é verdade, o que dá a contradição que queremos.\n\n## Exemplo\n\nSe você tem uma hipótese §26, então §27 resolve o objetivo, porque\n§28 sabe que §29 e isso basta para provar §30, que implica qualquer objetivo.\n\n## Exemplo\n\nSe você tem uma hipótese da forma §31 e seu objetivo é §32, então\n§33 resolve o objetivo, porque o objetivo é logicamente equivalente à hipótese.\nSe você trocar objetivo e hipótese neste exemplo, §34 também resolveria.", + "# Summary\n\nThe §0 tactic can be used to add new hypotheses to a level, but of course\nyou have to prove them.\n\n\n## Example\n\nThe simplest usage is like this. If you have §1 in your context and you execute\n\n§2\n\nthen you will get a new goal §3 to prove, and after you've proved\nit you will have a new hypothesis §4 in your original goal.\n\n## Example\n\nIf you already have a proof of what you want to §5, you\ncan just create it immediately. For example, if you have §6 and §7\nnumber objects, then\n\n§8\n\nwill directly add a new hypothesis §9\nto the context, because you just supplied the proof of it (§10).\n\n## Example\n\nIf you have a proof to hand, then you don't even need to state what you\nare proving. For example\n\n§11\n\nwill add §12 as a hypothesis.": + "# Resumo\n\nA tática §0 pode ser usada para adicionar novas hipóteses a um nível, mas é claro\nque você tem que prová-las.\n\n\n## Exemplo\n\nO uso mais simples é assim. Se você tem §1 no seu contexto e executa\n\n§2\n\nentão você vai ganhar um novo objetivo §3 para provar, e depois de tê-lo\nprovado você vai ter uma nova hipótese §4 no seu objetivo original.\n\n## Exemplo\n\nSe você já tem uma prova do que quer obter com §5, você\npode criá-la imediatamente. Por exemplo, se você tem os objetos numéricos §6 e §7,\nentão\n\n§8\n\nvai adicionar diretamente uma nova hipótese §9\nao contexto, porque você acabou de fornecer a prova dela (§10).\n\n## Exemplo\n\nSe você tem uma prova em mãos, então você nem precisa enunciar o que\nestá provando. Por exemplo\n\n§11\n\nvai adicionar §12 como hipótese.", + "# Summary\n\nIf you have a hypothesis\n\n§0\n\nand goal\n\n§1\n\nthen §2 replaces the set-up with its so-called \\\\\"contrapositive\\\\\":\na hypothesis\n\n§3\n\nand goal\n\n§4.": + "# Resumo\n\nSe você tem uma hipótese\n\n§0\n\ne o objetivo\n\n§1\n\nentão §2 substitui essa configuração pela sua chamada \\\\\"contrapositiva\\\\\":\numa hipótese\n\n§3\n\ne o objetivo\n\n§4.", + "# Statement\n\nIf §0 and §1 are numbers, then\n§2 is the proof that\n§3.\n\n## More technical details\n\nThere are other ways to think about §4.\n\nYou can think about §5 itself as a function which takes two\nnumbers §6 and §7 as input, and outputs a proof of\n§8.\n\nYou can think of §9 itself as a proof; it is the proof\nthat §10 is an injective function. In other words,\n§11 is a proof of\n§12.\n\n§13 was postulated as an axiom by Peano, but\nin Lean it can be proved using §14, a mathematically\npathological function.": + "# Enunciado\r\n\r\nSe §0 e §1 são números, então\r\n§2 é a prova de que\r\n§3.\r\n\r\n## Mais detalhes técnicos\r\n\r\nHá outras formas de interpretar §4.\r\n\r\nVocê pode interpretar a própria §5 como uma função que recebe dois\r\nnúmeros §6 e §7 como entrada, e devolve uma prova de que\r\n§8.\r\n\r\nVocê pode interpretar o próprio §9 como uma prova; é a prova\r\nde que §10 é uma função injetiva. Em outras palavras,\r\n§11 é prova de que\r\n§12.\r\n\r\n§13 foi postulado como axioma por Peano, mas\r\nem Lean pode ser provado usando §14, uma função\r\nmatematicamente patológica.", + "# Read this first\n\nEach level in this game involves proving a mathematical theorem (the \"Goal\").\nThe goal will be a statement about *numbers*. Some numbers in this game have known values.\nThose numbers have names like §0. Other numbers will be secret. They're called things\nlike §1 and §2. We know §3 is a number, we just don't know which one.\n\nIn this first level we're going to prove the theorem that §4.\nYou can see §5 in the *Objects* below, which means that §6 and §7\nare numbers.\n\nWe solve goals in Lean using *Tactics*, and the first tactic we're\ngoing to learn is called §8, which proves all theorems of the form §9.\n\nProve that §10 by executing the §11 tactic.": + "# Leia isto primeiro\n\nCada nível deste jogo envolve provar um teorema matemático (o \"Goal\", ou objetivo).\nO objetivo será um enunciado sobre *números*. Alguns números neste jogo têm valores conhecidos.\nEsses números têm nomes como §0. Outros números serão secretos. Eles têm nomes\ncomo §1 e §2. Sabemos que §3 é um número, só não sabemos qual.\n\nNeste primeiro nível vamos provar o teorema de que §4.\nVocê pode ver §5 nos *Objetos* abaixo, o que significa que §6 e §7\nsão números.\n\nResolvemos objetivos em Lean usando *Táticas*, e a primeira tática que\nvamos aprender se chama §8, que prova todos os teoremas da forma §9.\n\nProve que §10 executando a tática §11.", + "# Overview\n\nOur home-made tactic §0 will solve arbitrary goals of\nthe form §1.": + "# Visão geral\n\nNossa tática caseira §0 vai resolver objetivos arbitrários da\nforma §1.", + "# Overview\n\nLean's simplifier, §0, will rewrite every lemma\ntagged with §1 and every lemma fed to it by the user, as much as it can.\nFurthermore, it will attempt to order variables into an internal order if fed\nlemmas such as §2, so that it does not go into an infinite loop.": + "# Visão geral\n\nO simplificador do Lean, §0, vai reescrever todo lema\nmarcado com §1 e todo lema passado a ele pelo usuário, o máximo que conseguir.\nAlém disso, ele vai tentar ordenar as variáveis segundo uma ordem interna se receber\nlemas como §2, para não entrar em um loop infinito."} \ No newline at end of file diff --git a/.i18n/pt-BR/Game.po b/.i18n/pt-BR/Game.po new file mode 100644 index 00000000..fa087d3f --- /dev/null +++ b/.i18n/pt-BR/Game.po @@ -0,0 +1,6433 @@ +msgid "" +msgstr "" +"Project-Id-Version: Game v4.23.0\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2025-09-27\n" +"PO-Revision-Date: \n" +"Last-Translator: \n" +"Language-Team: none\n" +"Language: pt_BR\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Generator: Poedit 3.9\n" + +#: Game.Levels.LessOrEqual.L10le_one +msgid "x ≤ 1" +msgstr "x ≤ 1" + +#. §0: `tauto` +#: Game.Levels.AdvMultiplication.L06mul_right_eq_one +msgid "§0 is good enough to solve this goal." +msgstr "§0 já é o bastante para chegar no objetivo." + +#: Game.Levels.Multiplication.L09mul_assoc +msgid "mul_assoc" +msgstr "mul_assoc" + +#. §0: $a$ +#. §1: $b$ +#. §2: `succ_inj a b` +#. §3: $ (\\operatorname{succ}(a) = \\operatorname{succ}(b)) \\implies a=b$ +#. §4: `succ_inj` +#. §5: `succ_inj` +#. §6: $$a$$ +#. §7: $$b$$ +#. §8: $ ( \\operatorname{succ}(a) = \\operatorname{succ}(b)) \\implies a=b$ +#. §9: `succ_inj` +#. §10: `succ` +#. §11: `succ_inj` +#. §12: $\\forall a, b \\in \\mathbb{N}, ( \\operatorname{succ}(a) = +#. \\operatorname{succ}(b)) \\implies a=b$ +#. §13: `succ_inj` +#. §14: `pred` +#: Game.Levels.Implication.L04succ_inj +msgid "" +"# Statement\n" +"\n" +"If §0 and §1 are numbers, then\n" +"§2 is the proof that\n" +"§3.\n" +"\n" +"## More technical details\n" +"\n" +"There are other ways to think about §4.\n" +"\n" +"You can think about §5 itself as a function which takes two\n" +"numbers §6 and §7 as input, and outputs a proof of\n" +"§8.\n" +"\n" +"You can think of §9 itself as a proof; it is the proof\n" +"that §10 is an injective function. In other words,\n" +"§11 is a proof of\n" +"§12.\n" +"\n" +"§13 was postulated as an axiom by Peano, but\n" +"in Lean it can be proved using §14, a mathematically\n" +"pathological function." +msgstr "" +"# Enunciado\r\n" +"\r\n" +"Se §0 e §1 são números, então\r\n" +"§2 é a prova de que\r\n" +"§3.\r\n" +"\r\n" +"## Mais detalhes técnicos\r\n" +"\r\n" +"Há outras formas de interpretar §4.\r\n" +"\r\n" +"Você pode interpretar a própria §5 como uma função que recebe dois\r\n" +"números §6 e §7 como entrada, e devolve uma prova de que\r\n" +"§8.\r\n" +"\r\n" +"Você pode interpretar o próprio §9 como uma prova; é a prova\r\n" +"de que §10 é uma função injetiva. Em outras palavras,\r\n" +"§11 é prova de que\r\n" +"§12.\r\n" +"\r\n" +"§13 foi postulado como axioma por Peano, mas\r\n" +"em Lean pode ser provado usando §14, uma função\r\n" +"matematicamente patológica." + +#. §0: $a, b$ +#. §1: $ \\operatorname{succ}(a) + b = \\operatorname{succ}(a + b)$ +#: Game.Levels.Addition.L02succ_add +msgid "" +"For all natural numbers §0, we have\n" +"§1." +msgstr "" +"Para quaisquer números naturais §0, temos\r\n" +"§1." + +#. §0: `h` +#. §1: `X = Y` +#. §2: `rw [h]` +#. §3: `X` +#. §4: `Y` +#. §5: `Y` +#. §6: `X` +#. §7: `rw` +#. §8: `←` +#. §9: `\\l` +#. §10: $2$ +#. §11: $0$ +#. §12: `succ (succ 0)` +#. §13: `2` +#: Game.Levels.Tutorial.L04rw_backwards +msgid "" +"If §0 is a proof of §1 then §2 will\n" +"turn §3s into §4s. But what if we want to\n" +"turn §5s into §6s? To tell the §7 tactic\n" +"we want this, we use a left arrow §8. Type\n" +"§9 and then hit the space bar to get this arrow.\n" +"\n" +"Let's prove that §10 is the number after the number\n" +"after §11 again, this time by changing §12\n" +"into §13." +msgstr "" +"Se §0 é uma prova de §1, então §2 vai\n" +"transformar §3 em §4. Mas e se quisermos\n" +"transformar §5 em §6? Para dizer à tática §7\n" +"que é isso que queremos, usamos uma seta para a esquerda §8. Digite\n" +"§9 e aperte a barra de espaço para obter essa seta.\n" +"\n" +"Vamos provar de novo que §10 é o número depois do número\n" +"depois de §11, desta vez transformando §12\n" +"em §13." + +#. §0: `have` +#. §1: `a` +#. §2: `have ha : a = 0` +#. §3: `a = 0` +#. §4: `ha : a = 0` +#. §5: `have` +#. §6: `a` +#. §7: `b` +#. §8: `have h2 : succ a = succ b → a = b := succ_inj a b` +#. §9: `h2 : succ a = succ b → a = b` +#. §10: `succ_inj a b` +#. §11: `have h2 := succ_inj a b` +#. §12: `h2 : succ a = succ b → a = b` +#: Game.Levels.AdvMultiplication.L06mul_right_eq_one +msgid "" +"# Summary\n" +"\n" +"The §0 tactic can be used to add new hypotheses to a level, but of course\n" +"you have to prove them.\n" +"\n" +"\n" +"## Example\n" +"\n" +"The simplest usage is like this. If you have §1 in your context and you execute\n" +"\n" +"§2\n" +"\n" +"then you will get a new goal §3 to prove, and after you've proved\n" +"it you will have a new hypothesis §4 in your original goal.\n" +"\n" +"## Example\n" +"\n" +"If you already have a proof of what you want to §5, you\n" +"can just create it immediately. For example, if you have §6 and §7\n" +"number objects, then\n" +"\n" +"§8\n" +"\n" +"will directly add a new hypothesis §9\n" +"to the context, because you just supplied the proof of it (§10).\n" +"\n" +"## Example\n" +"\n" +"If you have a proof to hand, then you don't even need to state what you\n" +"are proving. For example\n" +"\n" +"§11\n" +"\n" +"will add §12 as a hypothesis." +msgstr "" +"# Resumo\n" +"\n" +"A tática §0 pode ser usada para adicionar novas hipóteses a um nível, mas é claro\n" +"que você tem que prová-las.\n" +"\n" +"\n" +"## Exemplo\n" +"\n" +"O uso mais simples é assim. Se você tem §1 no seu contexto e executa\n" +"\n" +"§2\n" +"\n" +"então você vai ganhar um novo objetivo §3 para provar, e depois de tê-lo\n" +"provado você vai ter uma nova hipótese §4 no seu objetivo original.\n" +"\n" +"## Exemplo\n" +"\n" +"Se você já tem uma prova do que quer obter com §5, você\n" +"pode criá-la imediatamente. Por exemplo, se você tem os objetos numéricos §6 e §7,\n" +"então\n" +"\n" +"§8\n" +"\n" +"vai adicionar diretamente uma nova hipótese §9\n" +"ao contexto, porque você acabou de fornecer a prova dela (§10).\n" +"\n" +"## Exemplo\n" +"\n" +"Se você tem uma prova em mãos, então você nem precisa enunciar o que\n" +"está provando. Por exemplo\n" +"\n" +"§11\n" +"\n" +"vai adicionar §12 como hipótese." + +#. §0: `≤` +#: Game.Levels.LessOrEqual.L11le_two +msgid "" +"Nice!\n" +"\n" +"The next step in the development of order theory is to develop\n" +"the theory of the interplay between §0 and multiplication.\n" +"If you've already done Multiplication World, you're now ready for\n" +"Advanced Multiplication World. Click on \"Leave World\" to access it." +msgstr "" +"Muito bem!\n" +"\n" +"O próximo passo no desenvolvimento da teoria da ordem é desenvolver\n" +"a teoria da interação entre §0 e a multiplicação.\n" +"Se você já passou pelo Mundo da Multiplicação, agora está pronto para\n" +"o Mundo da Multiplicação Avançada. Clique em \"Leave World\" para acessá-lo." + +#. §0: `a + b + c` +#. §1: `(a + b) + c` +#. §2: `+` +#: Game.Levels.Addition.L04add_assoc +msgid "" +"Remember that when Lean writes §0, it means §1.\n" +"If you are not sure where the brackets are in an expression, just hover\n" +"your cursor over it and look at what gets highlighted. For example,\n" +"hover over both §2 symbols on the left hand side of the goal and\n" +"you'll see where the invisible brackets are." +msgstr "" +"Lembre-se de que quando o Lean escreve §0, ele quer dizer §1.\n" +"Se você não tem certeza de onde estão os parênteses em uma expressão, basta passar\n" +"o mouse sobre ela e ver o que fica destacado. Por exemplo,\n" +"passe o mouse sobre os dois símbolos §2 no lado esquerdo do objetivo e\n" +"você vai ver onde estão os parênteses invisíveis." + +#. §0: `rw [← one_eq_succ_zero]` +#. §1: `succ 0` +#. §2: `1` +#: Game.Levels.Tutorial.L04rw_backwards +msgid "Try §0 to change §1 into §2." +msgstr "Tente §0 para transformar §1 em §2." + +#. §0: `1` +#: Game.Levels.Tutorial.L07add_succ +msgid "Start by unravelling the §0." +msgstr "Comece desembrulhando o §0." + +#: Game.Levels.Tutorial.L02rw +msgid "the rw tactic" +msgstr "a tática rw" + +#: Game.Levels.AdvMultiplication.L02mul_left_ne_zero +msgid "mul_left_ne_zero" +msgstr "mul_left_ne_zero" + +#: Game.Levels.AdvMultiplication.L07mul_ne_zero +msgid "mul_ne_zero" +msgstr "mul_ne_zero" + +#. §0: ``` +#. intro h +#. rw [add_succ, add_succ, add_zero] at h +#. repeat apply succ_inj at h +#. apply zero_ne_succ at h +#. exact h +#. ``` +#. §1: $20 + 20 ≠ 41$ +#: Game.Levels.Implication.L11two_add_two_ne_five +msgid "" +"Here's my proof:\n" +"§0\n" +"\n" +"Even though Lean is a theorem prover, right now it's pretty clear that we have not\n" +"developed enough material to make it an adequate calculator. In Algorithm\n" +"World, a more computer-sciency world, we will develop machinery which makes\n" +"questions like this much easier, and goals like §1 feasible.\n" +"Alternatively you can do more mathematics in Advanced Addition World, where we prove\n" +"the lemmas needed to get a working theory of inequalities. Click \"Leave World\" and\n" +"decide your route." +msgstr "" +"Aqui está a minha prova:\n" +"§0\n" +"\n" +"Mesmo o Lean sendo um provador de teoremas, agora está bem claro que ainda não\n" +"desenvolvemos material suficiente para torná-lo uma calculadora adequada. No Mundo dos\n" +"Algoritmos, um mundo mais de ciência da computação, vamos desenvolver ferramentas que tornam\n" +"perguntas como esta bem mais fáceis, e objetivos como §1 viáveis.\n" +"Como alternativa, você pode fazer mais matemática no Mundo da Adição Avançada, onde provamos\n" +"os lemas necessários para ter uma teoria funcional das desigualdades. Clique em \"Leave World\" e\n" +"decida o seu caminho." + +#. §0: `2 + 2 = 4` +#: Game.Levels.Tutorial +msgid "" +"Welcome to tutorial world! In this world we learn the basics\n" +"of proving theorems. The boss level of this world\n" +"is the theorem §0.\n" +"\n" +"You prove theorems by solving puzzles using tools called *tactics*.\n" +"The aim is to prove the theorem by applying tactics\n" +"in the right order.\n" +"\n" +"Let's learn some basic tactics. Click on \"Start\" below\n" +"to begin your quest." +msgstr "" +"Bem-vindo ao mundo do tutorial! Neste mundo aprendemos o básico\n" +"de como provar teoremas. O chefão deste mundo\n" +"é o teorema §0.\n" +"\n" +"Você prova teoremas resolvendo quebra-cabeças com ferramentas chamadas *táticas*.\n" +"O objetivo é provar o teorema aplicando táticas\n" +"na ordem certa.\n" +"\n" +"Vamos aprender algumas táticas básicas. Clique em \"Começar\" abaixo\n" +"para começar sua jornada." + +#: Game.Levels.AdvAddition.L02add_left_cancel +msgid "add_left_cancel" +msgstr "add_left_cancel" + +#: Game.Levels.LessOrEqual.L01le_refl +msgid "You can probably take it from here." +msgstr "Você provavelmente consegue seguir daqui." + +#: Game.Levels.Tutorial.L08twoaddtwo +msgid "2+2=4" +msgstr "2+2=4" + +#. §0: `x ≠ y` +#. §1: `x = y → False` +#: Game.Levels.Implication.L08ne +msgid "Remember, §0 is *notation* for §1." +msgstr "Lembre-se: §0 é *notação* para §1." + +#. §0: `a * b = 0` +#. §1: `a = 0` +#. §2: `b = 0` +#: Game.Levels.AdvMultiplication.L08mul_eq_zero +msgid "" +"This level proves that if §0 then §1 or §2. It is\n" +"logically equivalent to the last level, so there is a very short proof." +msgstr "" +"Este nível prova que se §0 então §1 ou §2. Isso é\n" +"logicamente equivalente ao nível anterior, então há uma prova bem curta." + +#. §0: $0+n=n$ +#. §1: $n$ +#. §2: $n+0=n$ +#. §3: `add_zero` +#. §4: `zero_add` +#. §5: `0 + n = n` +#. §6: `0 + n` +#. §7: `add_zero` +#. §8: `add_succ` +#. §9: `n` +#. §10: `0` +#. §11: `induction` +#. §12: `0 + 0 = 0` +#. §13: `0 + d = d` +#. §14: `0 + succ d = succ d` +#. §15: `0` +#. §16: `>_` +#: Game.Levels.Addition.L01zero_add +msgid "" +"In this level we're going to prove that §0, where §1 is a secret natural number.\n" +"\n" +"Wait, don't we already know that? No! We know that §2, but that's §3.\n" +"This is §4, which is different.\n" +"\n" +"The difficulty with proving §5 is that we do not have a *formula* for\n" +"§6 in general, we can only use §7 and §8 once\n" +"we know whether §9 is §10 or a successor. The §11 tactic splits into these two cases.\n" +"\n" +"The base case will require us to prove §12, and the inductive step\n" +"will ask us to show that if §13 then §14. Because\n" +"§15 and successor are the only way to make numbers, this will cover all the cases.\n" +"\n" +"See if you can do your first induction proof in Lean.\n" +"\n" +"(By the way, if you are still in the \"Editor mode\" from the last world, you can swap\n" +"back to \"Typewriter mode\" by clicking the §16 button in the top right.)" +msgstr "" +"Neste nível vamos provar que §0, onde §1 é um número natural secreto.\n" +"\n" +"Espera, a gente já não sabe disso? Não! Sabemos que §2, mas isso é §3.\n" +"Aqui é §4, que é diferente.\n" +"\n" +"A dificuldade de provar §5 é que não temos uma *fórmula* para\n" +"§6 em geral; só podemos usar §7 e §8 quando\n" +"sabemos se §9 é §10 ou um sucessor. A tática §11 divide nesses dois casos.\n" +"\n" +"O caso base vai exigir que provemos §12, e o passo indutivo\n" +"vai pedir que mostremos que se §13 então §14. Como\n" +"§15 e o sucessor são as únicas formas de construir números, isso cobre todos os casos.\n" +"\n" +"Veja se você consegue fazer sua primeira prova por indução em Lean.\n" +"\n" +"(A propósito, se você ainda estiver no \"Editor mode\" do mundo anterior, pode voltar\n" +"para o \"Typewriter mode\" clicando no botão §16 no canto superior direito.)" + +#. §0: `∨` +#. §1: `x = 0 ∨ x = 1 ∨ x = 2` +#. §2: `x = 0 ∨ (x = 1 ∨ x = 2)` +#. §3: `left` +#. §4: `right` +#: Game.Levels.LessOrEqual.L11le_two +msgid "" +"We'll need this lemma to prove that two is prime!\n" +"\n" +"You'll need to know that §0 is right associative. This means that\n" +"§1 actually means §2.\n" +"This affects how §3 and §4 work." +msgstr "" +"Vamos precisar deste lema para provar que dois é primo!\n" +"\n" +"Você precisa saber que §0 é associativo à direita. Isso significa que\n" +"§1 na verdade quer dizer §2.\n" +"Isso afeta como §3 e §4 funcionam." + +#: Game.Levels.Power.L01zero_pow_zero +msgid "zero_pow_zero" +msgstr "zero_pow_zero" + +#. §0: `a` +#. §1: `b` +#: Game.Levels.Addition.L03add_comm +msgid "Induction on §0 or §1 -- it's all the same in this one." +msgstr "Indução em §0 ou §1 -- neste aqui dá na mesma." + +#: Game.Levels.Power.L05pow_two +msgid "Note: this lemma will be useful for the final boss!" +msgstr "Nota: este lema será útil para o chefão final!" + +#: Game.Levels.Implication.L06intro +msgid "intro" +msgstr "intro" + +#. §0: `apply eq_succ_of_ne_zero at ha` +#: Game.Levels.AdvMultiplication.L04one_le_of_ne_zero +msgid "Use the previous lemma with §0." +msgstr "Use o lema anterior com §0." + +#: Game.Levels.Multiplication.L09mul_assoc +msgid "" +"A passing mathematician notes that you've proved\n" +"that the natural numbers are a commutative semiring.\n" +"\n" +"If you want to begin your journey to the final boss, head for Power World." +msgstr "" +"Um matemático que passava por aqui observa que você provou\n" +"que os números naturais formam um semianel comutativo.\n" +"\n" +"Se quiser começar sua jornada rumo ao chefão final, vá para o Mundo da Potência." + +#. §0: `pow_pow` +#: Game.Levels.Power.L08pow_pow +msgid "" +"One of the best named levels in the game, a savage §0\n" +"sub-boss appears as the music reaches a frenzy. What\n" +"else could there be to prove about powers after this?" +msgstr "" +"Um dos níveis com o melhor nome do jogo: um selvagem sub-chefão §0\n" +"aparece enquanto a música chega ao frenesi. O que mais\n" +"poderia restar para provar sobre potências depois disso?" + +#. §0: $x \\leq 0$ +#. §1: $x=0$ +#: Game.Levels.LessOrEqual.L05le_zero +msgid "If §0, then §1." +msgstr "Se §0, então §1." + +#. §0: `apply h` +#: Game.Levels.AdvMultiplication.L02mul_left_ne_zero +msgid "Now §0 and you can probably take it from here." +msgstr "Agora você faz §0 e provavelmente consegue seguir daqui." + +#. §0: `mul_comm x y : x * y = y * x` +#. §1: `zero_mul` +#. §2: `mul_zero` +#: Game.Levels.Multiplication.L04mul_comm +msgid "" +"The first sub-boss of Multiplication World is §0.\n" +"\n" +"When you've proved this theorem we will have \"spare\" proofs\n" +"such as §1, which is now easily deducible from §2.\n" +"But we'll keep hold of these proofs anyway, because it's convenient\n" +"to have exactly the right tool for a job." +msgstr "" +"O primeiro sub-chefão do Mundo da Multiplicação é §0.\n" +"\n" +"Quando você tiver provado esse teorema, teremos provas \"sobressalentes\"\n" +"como §1, que agora é facilmente dedutível de §2.\n" +"Mas vamos guardar essas provas mesmo assim, porque é conveniente\n" +"ter exatamente a ferramenta certa para cada trabalho." + +#. §0: `add_right_comm a b c` +#. §1: `(a + b) + c = (a + c) + b` +#. §2: `a + b + c` +#. §3: `(a + b) + c` +#. §4: `a + b + c = a + c + b` +#: Game.Levels.Addition.L05add_right_comm +msgid "" +"§0 is a proof that §1\n" +"\n" +"In Lean, §2 means §3, so this result gets displayed\n" +"as §4." +msgstr "" +"§0 é a prova de que §1\n" +"\n" +"Em Lean, §2 significa §3, então esse resultado é exibido\n" +"como §4." + +#: Game.Levels.Algorithm.L08decide +msgid "decide" +msgstr "decide" + +#. §0: `rw [zero_add] at «{h}»` +#. §1: `«{h}»` +#: Game.Levels.Implication.L02exact2 +msgid "" +"You can use §0 to rewrite at §1 instead\n" +"of at the goal." +msgstr "" +"Você pode usar §0 para reescrever em §1 em vez\n" +"de no objetivo." + +#. §0: `add_comm` +#. §1: `b` +#. §2: `d` +#: Game.Levels.Algorithm.L02add_algo1 +msgid "Finally use a targetted §0 to switch §1 and §2" +msgstr "Por fim, use um §0 direcionado para trocar §1 e §2" + +#. §0: `repeat t` +#. §1: `t` +#. §2: `repeat rw [add_zero]` +#. §3: `a + 0 + (0 + (0 + 0)) = b + 0 + 0` +#. §4: `a = b` +#: Game.Levels.Tutorial.L05add_zero +msgid "" +"## Summary\n" +"\n" +"§0 repeatedly applies the tactic §1\n" +"to the goal. You don't need to use this\n" +"tactic, it just speeds things up sometimes.\n" +"\n" +"## Example\n" +"\n" +"§2 will turn the goal\n" +"§3\n" +"into the goal\n" +"§4." +msgstr "" +"## Resumo\n" +"\n" +"§0 aplica repetidamente a tática §1\n" +"ao objetivo. Você não precisa usar essa\n" +"tática, ela só acelera as coisas às vezes.\n" +"\n" +"## Exemplo\n" +"\n" +"§2 transforma o objetivo\n" +"§3\n" +"no objetivo\n" +"§4." + +#: Game.Levels.Addition +msgid "Addition World" +msgstr "Mundo da Adição" + +#. §0: `P` +#. §1: `exact h` +#. §2: `h` +#. §3: `P` +#. §4: `x = 37` +#. §5: `h : x = 37` +#. §6: `exact h` +#. §7: `x + 0 = x` +#. §8: `exact add_zero x` +#. §9: `exact add_zero` +#. §10: `exact h` +#. §11: `h` +#. §12: `add_zero` +#. §13: `∀ n, n + 0 = n` +#. §14: `? + 0 = ?` +#. §15: `?` +#. §16: `rw` +#. §17: `apply` +#. §18: `x + 0 = x` +#. §19: `rw [add_zero]` +#. §20: `rw [add_zero x]` +#. §21: `x = x` +#. §22: `rw` +#. §23: `add_zero` +#: Game.Levels.Implication.L01exact +msgid "" +"## Summary\n" +"\n" +"If the goal is a statement §0, then §1 will close the goal if §2 is a proof of §3.\n" +"\n" +"### Example\n" +"\n" +"If the goal is §4 and you have a hypothesis §5\n" +"then §6 will solve the goal.\n" +"\n" +"### Example\n" +"\n" +"If the goal is §7 then §8 will close the goal.\n" +"\n" +"### Exact needs to be exactly right\n" +"\n" +"Note that §9 will *not work* in the previous example;\n" +"for §10 to work, §11 has to be *exactly* a proof of the goal.\n" +"§12 is a proof of §13 or, if you like,\n" +"a proof of §14 where §15 needs to be supplied by the user.\n" +"This is in contrast to §16 and §17, which will \\\\\"guess the inputs\\\\\"\n" +"if necessary. If the goal is §18 then §19\n" +"and §20 will both change the goal to §21,\n" +"because §22 guesses the input to the function §23." +msgstr "" +"## Resumo\n" +"\n" +"Se o objetivo é um enunciado §0, então §1 fecha o objetivo se §2 for uma prova de §3.\n" +"\n" +"### Exemplo\n" +"\n" +"Se o objetivo é §4 e você tem uma hipótese §5\n" +"então §6 resolve o objetivo.\n" +"\n" +"### Exemplo\n" +"\n" +"Se o objetivo é §7 então §8 fecha o objetivo.\n" +"\n" +"### Exact precisa ser exatamente certo\n" +"\n" +"Note que §9 *não funciona* no exemplo anterior;\n" +"para §10 funcionar, §11 tem que ser *exatamente* uma prova do objetivo.\n" +"§12 é uma prova de §13 ou, se preferir,\n" +"uma prova de §14 onde §15 precisa ser fornecido pelo usuário.\n" +"Isso contrasta com §16 e §17, que vão \\\\\"adivinhar as entradas\\\\\"\n" +"se necessário. Se o objetivo é §18 então §19\n" +"e §20 vão ambos mudar o objetivo para §21,\n" +"porque §22 adivinha a entrada da função §23." + +#. §0: `apply succ_inj at h` +#. §1: `succ` +#: Game.Levels.Implication.L07intro2 +msgid "Now §0 to cancel the §1s." +msgstr "Agora faça §0 para cancelar os §1." + +#. §0: `induction` +#. §1: `x + y = y + x` +#. §2: `rw` +#. §3: `rfl` +#. §4: `induction` +#: Game.Levels.Addition +msgid "" +"Welcome to Addition World! In this world we'll learn the §0 tactic.\n" +"This will enable us to defeat the boss level of this world, namely §1.\n" +"\n" +"The tactics §2, §3 and §4 are the only tactics you'll need to\n" +"beat all the levels in Addition World, Multiplication World, and Power World.\n" +"Power World contains the final boss of the game.\n" +"\n" +"There are plenty more tactics in this game, but you'll only need to know them if you\n" +"want to explore the game further (for example if you decide to 100%\n" +"the game)." +msgstr "" +"Bem-vindo ao Mundo da Adição! Neste mundo vamos aprender a tática §0.\n" +"Isso vai nos permitir derrotar o chefão deste mundo, a saber, §1.\n" +"\n" +"As táticas §2, §3 e §4 são as únicas de que você vai precisar para\n" +"vencer todos os níveis do Mundo da Adição, do Mundo da Multiplicação e do Mundo da Potência.\n" +"O Mundo da Potência contém o chefão final do jogo.\n" +"\n" +"Há muitas outras táticas neste jogo, mas você só vai precisar conhecê-las se\n" +"quiser explorar o jogo mais a fundo (por exemplo, se você decidir zerar\n" +"o jogo em 100%)." + +#. §0: `(a + a + 1) + (b + b + 1) = (a + b + 1) + (a + b + 1)` +#. §1: `(a + b) + (c + d) = ((a + c) + d) + b` +#. §2: `a+b+c+d` +#. §3: `a+c+d+b` +#. §4: `b` +#. §5: `c` +#. §6: `b` +#. §7: `d` +#. §8: `add_left_comm` +#: Game.Levels.Algorithm.L02add_algo1 +msgid "" +"In some later worlds, we're going to see some much nastier levels,\n" +"like §0.\n" +"Brackets need to be moved around, and variables need to be swapped.\n" +"\n" +"In this level, §1,\n" +"let's forget about the brackets and just think about\n" +"the variable order.\n" +"To turn §2 into §3 we need to swap §4 and §5,\n" +"and then swap §6 and §7. But this is easier than you\n" +"think with §8." +msgstr "" +"Em alguns mundos mais adiante, vamos ver níveis bem mais desagradáveis,\n" +"como §0.\n" +"Parênteses precisam ser movidos, e variáveis precisam ser trocadas de lugar.\n" +"\n" +"Neste nível, §1,\n" +"vamos esquecer os parênteses e pensar apenas\n" +"na ordem das variáveis.\n" +"Para transformar §2 em §3 precisamos trocar §4 e §5,\n" +"e depois trocar §6 e §7. Mas isso é mais fácil do que você\n" +"pensa com §8." + +#: Game.Levels.Algorithm.L01add_left_comm +msgid "add_left_comm" +msgstr "add_left_comm" + +#. §0: `symm` +#. §1: `X = Y` +#. §2: `Y = X` +#. §3: `X ≠ Y` +#. §4: `X ↔ Y` +#. §5: `2 + 2 = 4` +#. §6: `symm` +#. §7: `4 = 2 + 2` +#. §8: `h : 2 + 2 ≠ 5` +#. §9: `symm at h` +#. §10: `h` +#. §11: `5 ≠ 2 + 2` +#: Game.Levels.Implication.L10one_ne_zero +msgid "" +"## Summary\n" +"\n" +"The §0 tactic will change a goal or hypothesis of\n" +"the form §1 to §2. It will also work on §3\n" +"and on §4.\n" +"\n" +"### Example\n" +"\n" +"If the goal is §5 then §6 will change it to §7.\n" +"\n" +"### Example\n" +"\n" +"If §8 then §9 will change §10 to §11." +msgstr "" +"## Resumo\n" +"\n" +"A tática §0 transforma um objetivo ou uma hipótese da\n" +"forma §1 em §2. Ela também funciona com §3\n" +"e com §4.\n" +"\n" +"### Exemplo\n" +"\n" +"Se o objetivo é §5, então §6 vai mudá-lo para §7.\n" +"\n" +"### Exemplo\n" +"\n" +"Se §8, então §9 vai mudar §10 para §11." + +#. §0: $a$ +#. §1: $b$ +#. §2: $c$ +#. §3: $a(b + c) = ab + ac$ +#: Game.Levels.Multiplication.L07mul_add +msgid "" +"Multiplication is distributive over addition on the left.\n" +"In other words, for all natural numbers §0, §1 and §2, we have\n" +"§3." +msgstr "" +"A multiplicação é distributiva sobre a adição à esquerda.\n" +"Em outras palavras, para quaisquer números naturais §0, §1 e §2, temos\n" +"§3." + +#. §0: `apply` +#: Game.Levels.Implication.L03apply +msgid "The §0 tactic." +msgstr "A tática §0." + +#. §0: `exact h1` +#: Game.Levels.Implication.L01exact +msgid "The goal in this level is one of our hypotheses. Solve the goal by executing §0." +msgstr "O objetivo deste nível é uma das nossas hipóteses. Resolva o objetivo executando §0." + +#. §0: `≤` +#. §1: `a + b = 0` +#. §2: `a = 0` +#. §3: `b = 0` +#. §4: `cases` +#. §5: `cases` +#. §6: `b = 0` +#. §7: `b = succ d` +#. §8: `hd` +#. §9: `induction b with d hd` +#. §10: `cases b with d` +#. §11: `b = 0` +#. §12: `b = succ d` +#. §13: `h : False` +#. §14: `cases h` +#. §15: `False` +#: Game.Levels.AdvAddition.L05add_right_eq_zero +msgid "" +"The next result we'll need in §0 World is that if §1 then §2 and §3.\n" +"Let's prove one of these facts in this level, and the other in the next.\n" +"\n" +"## A new tactic: §4\n" +"\n" +"The §5 tactic will split an object or hypothesis up into the possible ways\n" +"that it could have been created.\n" +"\n" +"For example, sometimes you want to deal with the two cases §6 and §7 separately,\n" +"but don't need the inductive hypothesis §8 that comes with §9.\n" +"In this situation you can use §10 instead. There are two ways to make\n" +"a number: it's either zero or a successor. So you will end up with two goals, one\n" +"with §11 and one with §12.\n" +"\n" +"Another example: if you have a hypothesis §13 then you are done, because a false statement implies\n" +"any statement. Here §14 will close the goal, because there are *no* ways to\n" +"make a proof of §15! So you will end up with no goals, meaning you have proved everything." +msgstr "" +"O próximo resultado de que vamos precisar no Mundo do §0 é que, se §1, então §2 e §3.\n" +"Vamos provar um desses fatos neste nível, e o outro no próximo.\n" +"\n" +"## Uma nova tática: §4\n" +"\n" +"A tática §5 divide um objeto ou uma hipótese nas possíveis maneiras\n" +"pelas quais ele poderia ter sido criado.\n" +"\n" +"Por exemplo, às vezes você quer tratar os dois casos §6 e §7 separadamente,\n" +"mas não precisa da hipótese indutiva §8 que vem junto com §9.\n" +"Nessa situação você pode usar §10 no lugar. Há duas maneiras de construir\n" +"um número: ele é zero ou é um sucessor. Então você vai acabar com dois objetivos, um\n" +"com §11 e outro com §12.\n" +"\n" +"Outro exemplo: se você tem uma hipótese §13, então acabou, porque uma afirmação falsa implica\n" +"qualquer afirmação. Aqui §14 fecha o objetivo, porque *não há* maneira de\n" +"construir uma prova de §15! Então você vai acabar sem nenhum objetivo, o que significa que provou tudo." + +#. §0: `rfl` +#: Game.Levels.Tutorial.L01rfl +msgid "" +"In order to use the tactic §0 you can enter it in the text box\n" +"under the goal and hit \"Execute\"." +msgstr "" +"Para usar a tática §0 você pode digitá-la na caixa de texto\n" +"abaixo do objetivo e clicar em \"Execute\"." + +#. §0: $x=37$ +#. §1: $y=42$ +#. §2: $y=42$ +#. §3: $x=37$ +#: Game.Levels.LessOrEqual.L07or_symm +msgid "If §0 or §1, then §2 or §3." +msgstr "Se §0 ou §1, então §2 ou §3." + +#: Game.Levels.Algorithm.L09decide2 +msgid "" +"Congratulations! You've finished Algorithm World. These algorithms\n" +"will be helpful for you in Even-Odd World (when someone gets around to\n" +"implementing it)." +msgstr "" +"Parabéns! Você terminou o Mundo do Algoritmo. Esses algoritmos\n" +"vão te ajudar no Mundo dos Pares e Ímpares (quando alguém finalmente\n" +"implementá-lo)." + +#. §0: `h : X = Y` +#. §1: `rw [h]` +#. §2: `X` +#. §3: `Y` +#. §4: `nth_rewrite 3 [h]` +#: Game.Levels.Tutorial.L08twoaddtwo +msgid "" +"Good luck!\n" +"\n" +" One last hint. If §0 then §1 will change *all* §2s into §3s.\n" +" If you only want to change one of them, say the 3rd one, then use\n" +" §4." +msgstr "" +"Boa sorte!\n" +"\n" +" Uma última dica. Se §0, então §1 vai mudar *todos* os §2 em §3.\n" +" Se você quiser mudar apenas um deles, digamos o terceiro, use\n" +" §4." + +#. §0: `add_assoc` +#. §1: `add_comm` +#: Game.Levels.Addition.L04add_assoc +msgid "" +"A passing mathematician congratulates you on proving that naturals\n" +"are an additive commutative monoid.\n" +"\n" +"Let's practice using §0 and §1 in one more level,\n" +"before we leave addition world." +msgstr "" +"Um matemático que passava por aqui te parabeniza por provar que os naturais\n" +"formam um monoide comutativo aditivo.\n" +"\n" +"Vamos praticar o uso de §0 e §1 em mais um nível,\n" +"antes de deixarmos o mundo da adição." + +#: Game.Levels.Implication.L05succ_inj2 +msgid "Arguing backwards" +msgstr "Argumentando de trás para frente" + +#: Game.Levels.AdvMultiplication.L06mul_right_eq_one +msgid "mul_right_eq_one" +msgstr "mul_right_eq_one" + +#. §0: `add_sq a b` +#. §1: $(a+b)^2=a^2+b^2+2ab.$ +#: Game.Levels.Power.L09add_sq +msgid "§0 is the statement that §1" +msgstr "§0 é o enunciado de que §1" + +#. §0: $x=y$ +#. §1: $x \\neq y$ +#: Game.Levels.Implication.L08ne +msgid "If §0 and §1 then we can deduce a contradiction." +msgstr "Se §0 e §1 então podemos deduzir uma contradição." + +#. §0: `2 + 2 = 4` +#. §1: $37$ +#. §2: $x$ +#. §3: $0$ +#. §4: `37 + x` +#. §5: `37 + 0` +#. §6: `37 + succ x` +#. §7: `0` +#. §8: `37 + 0` +#. §9: `37` +#. §10: `a + 0` +#. §11: `a` +#. §12: `a` +#. §13: `add_zero a` +#. §14: `add_zero 37` +#. §15: `37 + 0 = 37` +#. §16: `add_zero x` +#. §17: `x + 0 = x` +#. §18: `add_zero` +#. §19: `? + 0 = ?` +#. §20: `add_zero x : x + 0 = x` +#. §21: `proof : statement` +#: Game.Levels.Tutorial.L05add_zero +msgid "" +"We'd like to prove §0 but right now\n" +"we can't even *state* it\n" +"because we haven't yet defined addition.\n" +"\n" +"## Defining addition.\n" +"\n" +"How are we going to add §1 to an arbitrary number §2? Well,\n" +"there are only two ways to make numbers in this game: §3\n" +"and successors. So to define §4 we will need\n" +"to know what §5 is and what §6 is.\n" +"Let's start with adding §7.\n" +"\n" +"### Adding 0\n" +"\n" +"To make addition agree with our intuition, we should *define* §8\n" +"to be §9. More generally, we should define §10 to be §11 for\n" +"any number §12. The name of this proof in Lean is §13.\n" +"For example §14 is a proof of §15,\n" +"§16 is a proof of §17, and §18 is a proof\n" +"of §19.\n" +"\n" +"We write §20, so §21." +msgstr "" +"Gostaríamos de provar §0 mas neste momento\n" +"nem sequer conseguimos *enunciar* isso\n" +"porque ainda não definimos a adição.\n" +"\n" +"## Definindo a adição.\n" +"\n" +"Como vamos somar §1 a um número arbitrário §2? Bem,\n" +"só existem duas maneiras de construir números neste jogo: §3\n" +"e sucessores. Então, para definir §4 vamos precisar\n" +"saber o que é §5 e o que é §6.\n" +"Vamos começar somando §7.\n" +"\n" +"### Somando 0\n" +"\n" +"Para que a adição concorde com nossa intuição, devemos *definir* §8\n" +"como §9. De modo mais geral, devemos definir §10 como §11 para\n" +"qualquer número §12. O nome dessa prova em Lean é §13.\n" +"Por exemplo, §14 é uma prova de §15,\n" +"§16 é uma prova de §17, e §18 é uma prova\n" +"de §19.\n" +"\n" +"Escrevemos §20, ou seja, `prova : enunciado`." + +#. §0: `t = 0` +#: Game.Levels.AdvMultiplication.L01mul_le_mul_right +msgid "Let's warm up with an easy one, which works even if §0." +msgstr "Vamos aquecer com um fácil, que vale mesmo se §0." + +#. §0: $x+1=y+1\\implies x=y$ +#: Game.Levels.Implication.L07intro2 +msgid "" +"Let's see if you can use the tactics we've learnt to prove §0.\n" +"Try this one by yourself; if you need help then click on \"Show more help!\"." +msgstr "" +"Vamos ver se você consegue usar as táticas que aprendemos para provar §0.\n" +"Tente este sozinho; se precisar de ajuda, clique em \"Mostrar mais ajuda!\"." + +#. §0: `apply zero_ne_succ at h` +#: Game.Levels.Implication.L09zero_ne_succ Game.Levels.AdvMultiplication.L06mul_right_eq_one +msgid "Now you can §0." +msgstr "Agora você pode fazer §0." + +#. §0: $37$ +#. §1: $x$ +#. §2: $q$ +#. §3: $x$ +#. §4: $37x + q = 37x + q$ +#. §5: `x q : ℕ` +#. §6: `x` +#. §7: `q` +#. §8: `rfl` +#. §9: $X = X$ +#. §10: $37x+q=37x+q$ +#. §11: `rfl` +#: Game.Levels.Tutorial.L01rfl +msgid "" +"# Read this first\n" +"\n" +"Each level in this game involves proving a mathematical theorem (the \"Goal\").\n" +"The goal will be a statement about *numbers*. Some numbers in this game have known values.\n" +"Those numbers have names like §0. Other numbers will be secret. They're called things\n" +"like §1 and §2. We know §3 is a number, we just don't know which one.\n" +"\n" +"In this first level we're going to prove the theorem that §4.\n" +"You can see §5 in the *Objects* below, which means that §6 and §7\n" +"are numbers.\n" +"\n" +"We solve goals in Lean using *Tactics*, and the first tactic we're\n" +"going to learn is called §8, which proves all theorems of the form §9.\n" +"\n" +"Prove that §10 by executing the §11 tactic." +msgstr "" +"# Leia isto primeiro\n" +"\n" +"Cada nível deste jogo envolve provar um teorema matemático (o \"Goal\", ou objetivo).\n" +"O objetivo será um enunciado sobre *números*. Alguns números neste jogo têm valores conhecidos.\n" +"Esses números têm nomes como §0. Outros números serão secretos. Eles têm nomes\n" +"como §1 e §2. Sabemos que §3 é um número, só não sabemos qual.\n" +"\n" +"Neste primeiro nível vamos provar o teorema de que §4.\n" +"Você pode ver §5 nos *Objetos* abaixo, o que significa que §6 e §7\n" +"são números.\n" +"\n" +"Resolvemos objetivos em Lean usando *Táticas*, e a primeira tática que\n" +"vamos aprender se chama §8, que prova todos os teoremas da forma §9.\n" +"\n" +"Prove que §10 executando a tática §11." + +#. §0: ``` +#. repeat rw [zero_add] at h +#. exact h +#. ``` +#: Game.Levels.Implication.L02exact2 +msgid "" +"Here's a two-line proof:\n" +"§0" +msgstr "" +"Aqui está uma prova de duas linhas:\n" +"§0" + +#. §0: `zero_add x` +#. §1: `0 + x = x` +#. §2: `zero_add` +#. §3: `simp` +#. §4: `0 + x` +#. §5: `x` +#: Game.Levels.Addition.L01zero_add +msgid "" +"§0 is the proof of §1.\n" +"\n" +"§2 is a §3 lemma, because replacing §4 by §5\n" +"is almost always what you want to do if you're simplifying an expression." +msgstr "" +"§0 é a prova de §1.\n" +"\n" +"§2 é um lema §3, porque substituir §4 por §5\n" +"é quase sempre o que você quer fazer ao simplificar uma expressão." + +#. §0: `a` +#. §1: `b` +#. §2: `succ_inj a b` +#. §3: `succ a = succ b` +#. §4: `a = b` +#. §5: $x+1=4 \\implies x=3$ +#: Game.Levels.Implication.L04succ_inj +msgid "" +"If §0 and §1 are numbers, then §2 is a proof\n" +"that §3 implies §4. Click on this theorem in the *Peano*\n" +"tab for more information.\n" +"\n" +"Peano had this theorem as an axiom, but in Algorithm World\n" +"we will show how to prove it in Lean. Right now let's just assume it,\n" +"and let's prove §5 using it. Again, we will proceed\n" +"by manipulating our hypothesis until it becomes the goal. I will\n" +"walk you through this level." +msgstr "" +"Se §0 e §1 são números, então §2 é a prova\n" +"de que §3 implica §4. Clique neste teorema na aba *Peano*\n" +"para mais informações.\n" +"\n" +"Peano tinha este teorema como axioma, mas no Mundo dos Algoritmos\n" +"vamos mostrar como prová-lo em Lean. Por enquanto vamos só assumi-lo,\n" +"e vamos provar §5 usando ele. De novo, vamos proceder\n" +"manipulando nossa hipótese até que ela se torne o objetivo. Vou\n" +"te guiar por este nível." + +#. §0: `2 + 2 ≠ 5` +#. §1: `0 ≠ 1` +#. §2: `zero_ne_succ n` +#. §3: `0 ≠ succ n` +#: Game.Levels.Implication.L09zero_ne_succ +msgid "" +"As warm-up for §0 let's prove §1. To do this we need to\n" +"introduce Peano's last axiom §2, a proof that §3.\n" +"To learn about this result, click on it in the list of lemmas on the right." +msgstr "" +"Como aquecimento para §0, vamos provar §1. Para isso precisamos\n" +"introduzir o último axioma de Peano, §2, uma prova de que §3.\n" +"Para aprender sobre esse resultado, clique nele na lista de lemas à direita." + +#. §0: $x+y=37$ +#. §1: $3x+z=42$ +#. §2: $x+y=37$ +#: Game.Levels.Implication.L01exact +msgid "Assuming §0 and §1, we have §2." +msgstr "Supondo §0 e §1, temos §2." + +#. §0: `a` +#. §1: `b` +#. §2: $a + b = b + a$ +#: Game.Levels.Addition.L03add_comm +msgid "" +"On the set of natural numbers, addition is commutative.\n" +"In other words, if §0 and §1 are arbitrary natural numbers, then\n" +"§2." +msgstr "" +"No conjunto dos números naturais, a adição é comutativa.\n" +"Em outras palavras, se §0 e §1 são números naturais arbitrários, então\n" +"§2." + +#. §0: `a * b = a * c` +#. §1: `a ≠ 0` +#. §2: `b = c` +#. §3: `induction b with d hd` +#. §4: `a * d = a * c → d = c` +#. §5: `a * succ d = a * c` +#. §6: `a ≠ 0` +#. §7: `b` +#. §8: `c` +#. §9: `a * b = a * c` +#. §10: `b = c` +#. §11: `c` +#: Game.Levels.AdvMultiplication.L09mul_left_cancel +msgid "" +"In this level we prove that if §0 and §1 then §2. It is tricky, for\n" +"several reasons. One of these is that\n" +"we need to introduce a new idea: we will need to understand the concept of\n" +"mathematical induction a little better.\n" +"\n" +"Starting with §3 is too naive, because in the inductive step\n" +"the hypothesis is §4 but what we know is §5,\n" +"so the induction hypothesis does not apply!\n" +"\n" +"Assume §6 is fixed. The actual statement we want to prove by induction on §7 is\n" +"\"for all §8, if §9 then §10\". This *can* be proved by induction,\n" +"because we now have the flexibility to change §11." +msgstr "" +"Neste nível provamos que se §0 e §1, então §2. É complicado, por\n" +"várias razões. Uma delas é que\n" +"precisamos introduzir uma ideia nova: vamos precisar entender um pouco melhor\n" +"o conceito de indução matemática.\n" +"\n" +"Começar com §3 é ingênuo demais, porque no passo indutivo\n" +"a hipótese é §4 mas o que sabemos é §5,\n" +"então a hipótese de indução não se aplica!\n" +"\n" +"Suponha que §6 esteja fixo. O enunciado que realmente queremos provar por indução em §7 é\n" +"\"para todo §8, se §9 então §10\". Isso *pode* ser provado por indução,\n" +"porque agora temos a flexibilidade de mudar §11." + +#. §0: `h2` +#. §1: `tauto` +#: Game.Levels.AdvMultiplication.L08mul_eq_zero +msgid "" +"Now the goal can be deduced from §0 by pure logic, so use the §1\n" +"tactic." +msgstr "Agora o objetivo pode ser deduzido de §0 por lógica pura, então use a tática §1." + +#. §0: `rfl` +#: Game.Levels.Tutorial.L02rw +msgid "Now §0 will work." +msgstr "Agora §0 vai funcionar." + +#. §0: `le_zero x` +#. §1: `x ≤ 0 → x = 0` +#: Game.Levels.LessOrEqual.L05le_zero +msgid "§0 is a proof of the implication §1." +msgstr "§0 é uma prova da implicação §1." + +#: Game.Levels.Implication.L11two_add_two_ne_five +msgid "2 + 2 ≠ 5" +msgstr "2 + 2 ≠ 5" + +#. §0: `ℕ` +#. §1: `0 : ℕ` +#. §2: `succ (n : ℕ) : ℕ` +#. §3: `MyNat` +#. §4: `ℕ` +#. §5: `Nat` +#: Game.Levels.Tutorial.L03two_eq_ss0 +msgid "" +"§0 is the natural numbers, just called \\\\\"numbers\\\\\" in this game. It's\n" +"defined via two rules:\n" +"\n" +"* §1 (zero is a number)\n" +"* §2 (the successor of a number is a number)\n" +"\n" +"## Game Implementation\n" +"\n" +"*The game uses its own copy of the natural numbers, called §3 with notation §4.\n" +"It is distinct from the Lean natural numbers §5, which should hopefully\n" +"never leak into the natural number game.*" +msgstr "" +"§0 são os números naturais, chamados apenas de \\\\\"números\\\\\" neste jogo. Eles são\n" +"definidos por duas regras:\n" +"\n" +"* §1 (zero é um número)\n" +"* §2 (o sucessor de um número é um número)\n" +"\n" +"## Implementação do jogo\n" +"\n" +"*O jogo usa sua própria cópia dos números naturais, chamada §3 com a notação §4.\n" +"Ela é distinta dos números naturais do Lean, §5, que, esperamos,\n" +"nunca vazem para dentro do jogo dos números naturais.*" + +#. §0: `a ≠ 0` +#. §1: `tauto` +#: Game.Levels.AdvMultiplication.L03eq_succ_of_ne_zero +msgid "" +"Multiplication usually makes a number bigger, but multiplication by zero can make\n" +"it smaller. Thus many lemmas about inequalities and multiplication need the\n" +"hypothesis §0. Here is a key lemma that enables us to use this hypothesis.\n" +"To help us with the proof, we can use the §1 tactic. Click on the tactic's name\n" +"on the right to see what it does." +msgstr "" +"A multiplicação geralmente deixa um número maior, mas a multiplicação por zero pode deixá-lo\n" +"menor. Por isso muitos lemas sobre desigualdades e multiplicação precisam da\n" +"hipótese §0. Aqui está um lema chave que nos permite usar essa hipótese.\n" +"Para nos ajudar na prova, podemos usar a tática §1. Clique no nome da tática\n" +"à direita para ver o que ela faz." + +#. §0: `cases` +#. §1: `hxy` +#: Game.Levels.LessOrEqual.L04le_trans +msgid "" +"In this level, we see inequalities as *hypotheses*. We have not seen this before.\n" +"The §0 tactic can be used to take §1 apart." +msgstr "" +"Neste nível, vemos desigualdades como *hipóteses*. Não tínhamos visto isso antes.\n" +"A tática §0 pode ser usada para desmontar §1." + +#. §0: `a` +#. §1: `b` +#. §2: `a = b` +#. §3: `a` +#. §4: `b` +#. §5: `0` +#. §6: `a` +#. §7: `b` +#. §8: `0` +#. §9: `0` +#. §10: `succ n` +#. §11: `a = succ m` +#. §12: `b = succ n` +#. §13: `m = n` +#. §14: `0 = 0` +#. §15: `rfl` +#. §16: `0 ≠ succ n` +#. §17: `zero_ne_succ n` +#. §18: `succ m ≠ 0` +#. §19: `succ_ne_zero m` +#. §20: `h : m = n` +#. §21: `succ m = succ n` +#. §22: `rw [h]` +#. §23: `rfl` +#. §24: `a ≠ b` +#. §25: `succ a ≠ succ b` +#: Game.Levels.Algorithm.L07succ_ne_succ +msgid "" +"Here we begin to\n" +"develop an algorithm which, given two naturals §0 and §1, returns the answer\n" +"to \"does §2?\"\n" +"\n" +"Here is the algorithm. First note that §3 and §4 are numbers, and hence\n" +"are either §5 or successors.\n" +"\n" +"*) If §6 and §7 are both §8, return \"yes\".\n" +"\n" +"*) If one is §9 and the other is §10, return \"no\".\n" +"\n" +"*) If §11 and §12, then return the answer to \"does §13?\"\n" +"\n" +"Our job now is to *prove* that this algorithm always gives the correct answer. The proof that\n" +"§14 is §15. The proof that §16 is §17, and the proof\n" +"that §18 is §19. The proof that if §20 then\n" +"§21 is §22 and then §23. This level is a proof of the one\n" +"remaining job we have to do: if §24 then §25." +msgstr "" +"Aqui começamos a\n" +"desenvolver um algoritmo que, dados dois naturais §0 e §1, devolve a resposta\n" +"para \"será que §2?\"\n" +"\n" +"Eis o algoritmo. Primeiro note que §3 e §4 são números e, portanto,\n" +"são §5 ou sucessores.\n" +"\n" +"*) Se §6 e §7 forem ambos §8, devolva \"sim\".\n" +"\n" +"*) Se um for §9 e o outro for §10, devolva \"não\".\n" +"\n" +"*) Se §11 e §12, então devolva a resposta para \"será que §13?\"\n" +"\n" +"Nosso trabalho agora é *provar* que esse algoritmo sempre dá a resposta correta. A prova de que\n" +"§14 é §15. A prova de que §16 é §17, e a prova\n" +"de que §18 é §19. A prova de que, se §20, então\n" +"§21 é §22 e depois §23. Este nível é a prova da única\n" +"tarefa que nos resta: se §24 então §25." + +#: Game.Levels.LessOrEqual.L06le_antisymm +msgid "x ≤ y and y ≤ x implies x = y" +msgstr "x ≤ y e y ≤ x implica x = y" + +#. §0: `left` +#. §1: `P ∨ Q` +#. §2: `P` +#. §3: `P ∨ Q` +#. §4: `P` +#. §5: `apply` +#. §6: $P \\implies P \\lor Q.$ +#: Game.Levels.LessOrEqual.L07or_symm +msgid "" +"# Summary\n" +"The §0 tactic changes a goal of §1 into a goal of §2.\n" +"Use it when your hypotheses guarantee that the reason that §3\n" +"is true is because in fact §4 is true.\n" +"\n" +"Internally this tactic is just §5ing a theorem\n" +"saying that §6\n" +"\n" +"Note that this tactic can turn a solvable goal into an unsolvable\n" +"one." +msgstr "" +"# Resumo\n" +"A tática §0 transforma um objetivo §1 em um objetivo §2.\n" +"Use-a quando suas hipóteses garantirem que a razão de §3\n" +"ser verdadeiro é que, na verdade, §4 é verdadeiro.\n" +"\n" +"Internamente, essa tática apenas faz §5 de um teorema\n" +"dizendo que §6\n" +"\n" +"Note que essa tática pode transformar um objetivo solúvel em um\n" +"insolúvel." + +#: Game.Levels.Multiplication +msgid "Multiplication World" +msgstr "Mundo da Multiplicação" + +#. §0: `le_zero` +#. §1: `x ≤ 0` +#. §2: `x = 0` +#. §3: `x ≤ 1` +#. §4: `x = 0` +#. §5: `x = 1` +#: Game.Levels.LessOrEqual.L10le_one +msgid "" +"We've seen §0, the proof that if §1 then §2.\n" +"Now we'll prove that if §3 then §4 or §5." +msgstr "" +"Já vimos §0, a prova de que se §1 então §2.\n" +"Agora vamos provar que se §3 então §4 ou §5." + +#. §0: $\\mathbb{N}$ +#: Game +msgid "" +"In this game you recreate the natural numbers §0 from the Peano axioms,\n" +"learning the basics about theorem proving in Lean.\n" +"\n" +"This is a good first introduction to Lean!" +msgstr "" +"Neste jogo você recria os números naturais §0 a partir dos axiomas de Peano,\n" +"aprendendo o básico sobre como provar teoremas em Lean.\n" +"\n" +"Esta é uma boa primeira introdução ao Lean!" + +#. §0: `Add a b` +#. §1: `a + b` +#. §2: `add_zero a : a + 0 = a` +#. §3: `add_succ a b : a + succ b = succ (a + b)` +#. §4: `zero_add a : 0 + a = a` +#: Game.Levels.Tutorial.L05add_zero +msgid "" +"§0, with notation §1, is\n" +"the usual sum of natural numbers. Internally it is defined\n" +"via the following two hypotheses:\n" +"\n" +"* §2\n" +"\n" +"* §3\n" +"\n" +"Other theorems about naturals, such as §4, are proved\n" +"by induction using these two basic theorems.\"" +msgstr "" +"§0, com a notação §1, é\n" +"a soma usual de números naturais. Internamente ela é definida\n" +"pelas duas hipóteses seguintes:\n" +"\n" +"* §2\n" +"\n" +"* §3\n" +"\n" +"Outros teoremas sobre os naturais, como §4, são provados\n" +"por indução usando esses dois teoremas básicos.\"" + +#. §0: $x+1=4$ +#. §1: $x=3$ +#: Game.Levels.Implication.L04succ_inj Game.Levels.Implication.L05succ_inj2 Game.Levels.Algorithm.L05pred +#: Game.Levels.Algorithm.L07succ_ne_succ Game.Levels.AdvAddition.L05add_right_eq_zero +#: Game.Levels.AdvAddition.L06add_left_eq_zero Game.Levels.LessOrEqual.L09succ_le_succ +msgid "If §0 then §1." +msgstr "Se §0 então §1." + +#. §0: $x+y+z$ +#. §1: $(x+y)+z$ +#. §2: $x+(y+z)$ +#. §3: $x+y+z$ +#. §4: $(x+y)+z$ +#. §5: $(x+y)+z$ +#. §6: $x+(y+z)$ +#: Game.Levels.Addition.L04add_assoc +msgid "" +"We've been adding up two numbers; in this level we will add up three.\n" +"\n" +" What does §0 *mean*? It could either mean §1, or it\n" +" could mean §2. In Lean, §3 means §4.\n" +"\n" +" But why do we care which one it means; §5 and §6 are *equal*!\n" +"\n" +" That's true, but we didn't prove it yet. Let's prove it now by induction." +msgstr "" +"Estivemos somando dois números; neste nível vamos somar três.\n" +"\n" +" O que §0 *significa*? Pode significar §1, ou pode\n" +" significar §2. Em Lean, §3 significa §4.\n" +"\n" +" Mas por que nos importamos com qual dos dois significa; §5 e §6 são *iguais*!\n" +"\n" +" É verdade, mas ainda não provamos isso. Vamos provar agora por indução." + +#. §0: `add_left_eq_self` +#. §1: ``` +#. rw [add_comm] +#. intro h +#. apply add_left_eq_self at h +#. exact h +#. ``` +#. §2: ``` +#. rw [add_comm] +#. exact add_left_eq_self y x +#. ``` +#. §3: `x` +#. §4: ``` +#. induction x with d hd +#. intro h +#. rw [zero_add] at h +#. exact h +#. intro h +#. rw [succ_add] at h +#. apply succ_inj at h +#. apply hd at h +#. exact h +#. ``` +#: Game.Levels.AdvAddition.L04add_right_eq_self +msgid "" +"Here's a proof using §0:\n" +"§1\n" +"\n" +"and here's an even shorter one using the same idea:\n" +"§2\n" +"\n" +"Alternatively you can just prove it by induction on §3:\n" +"\n" +"§4" +msgstr "" +"Aqui está uma prova usando §0:\n" +"§1\n" +"\n" +"e aqui está uma ainda mais curta usando a mesma ideia:\n" +"§2\n" +"\n" +"Como alternativa, você pode simplesmente provar por indução em §3:\n" +"\n" +"§4" + +#. §0: `add_right_eq_zero` +#. §1: `symm at` +#: Game.Levels.LessOrEqual.L05le_zero +msgid "" +"You want to use §0, which you already\n" +"proved, but you'll have to start with §1 your hypothesis." +msgstr "" +"Você quer usar §0, que você já\n" +"provou, mas vai ter que começar com §1 na sua hipótese." + +#. §0: `1` +#. §1: `succ 0` +#. §2: `rw [one_eq_succ_zero]` +#: Game.Levels.Tutorial.L03two_eq_ss0 +msgid "Next turn §0 into §1 with §2." +msgstr "Em seguida transforme §0 em §1 com §2." + +#: Game.Levels.Implication.L07intro2 +msgid "intro practice" +msgstr "praticando intro" + +#. §0: `n : ℕ` +#. §1: `n` +#. §2: `induction n with d hd` +#. §3: `n` +#. §4: `d` +#. §5: `hd` +#. §6: ``` +#. 0 + n = n +#. ``` +#. §7: `induction n with d hd` +#. §8: `0 + 0 = 0` +#. §9: `hd : 0 + d = d` +#. §10: `0 + succ d = succ d` +#: Game.Levels.Addition.L01zero_add +msgid "" +"## Summary\n" +"\n" +"If §0 is an object, and the goal mentions §1, then §2\n" +"attempts to prove the goal by induction on §3, with the inductive\n" +"variable in the successor case being §4, and the inductive hypothesis being §5.\n" +"\n" +"### Example:\n" +"If the goal is\n" +"§6\n" +"\n" +"then\n" +"\n" +"§7\n" +"\n" +"will turn it into two goals. The first is §8;\n" +"the second has an assumption §9 and goal\n" +"§10.\n" +"\n" +"Note that you must prove the first\n" +"goal before you can access the second one." +msgstr "" +"## Resumo\n" +"\n" +"Se §0 é um objeto, e o objetivo menciona §1, então §2\n" +"tenta provar o objetivo por indução em §3, sendo a variável indutiva\n" +"no caso do sucessor §4, e a hipótese indutiva §5.\n" +"\n" +"### Exemplo:\n" +"Se o objetivo é\n" +"§6\n" +"\n" +"então\n" +"\n" +"§7\n" +"\n" +"vai transformá-lo em dois objetivos. O primeiro é §8;\n" +"o segundo tem uma hipótese §9 e objetivo\n" +"§10.\n" +"\n" +"Note que você precisa provar o primeiro\n" +"objetivo antes de poder acessar o segundo." + +#: Game.Levels.Implication.L09zero_ne_succ +msgid "zero_ne_succ" +msgstr "zero_ne_succ" + +#. §0: $1\\times m=m$ +#. §1: `succ_mul` +#: Game.Levels.Multiplication.L05one_mul +msgid "" +"You can prove §0 in at least three ways.\n" +"Either by induction, or by using §1, or\n" +"by using commutativity. Which do you think is quickest?" +msgstr "" +"Você pode provar §0 de pelo menos três jeitos.\n" +"Ou por indução, ou usando §1, ou\n" +"usando comutatividade. Qual você acha que é o mais rápido?" + +#. §0: `succ a + «{d}»` +#. §1: `(succ a) + «{d}»` +#. §2: `succ` +#: Game.Levels.Addition.L02succ_add +msgid "" +"Note that §0 means §1. Put your cursor\n" +"on any §2 in the goal or assumptions to see what exactly it's eating." +msgstr "" +"Note que §0 significa §1. Coloque o cursor\n" +"sobre qualquer §2 no objetivo ou nas hipóteses para ver exatamente o que ele está comendo." + +#. §0: `cases «{h}» with hx hy` +#: Game.Levels.LessOrEqual.L07or_symm +msgid "We don't know whether to go left or right yet. So start with §0." +msgstr "Ainda não sabemos se vamos para a esquerda ou para a direita. Então comece com §0." + +#. §0: $2$ +#. §1: $2 = 37 × 42.$ +#. §2: $2$ +#. §3: $2$ +#. §4: `mul_left_ne_zero` +#. §5: `one_le_of_ne_zero` +#. §6: `mul_le_mul_right` +#: Game.Levels.AdvMultiplication.L05le_mul_right +msgid "" +"One day this game will have a Prime Number World, with a final boss\n" +"of proving that §0 is prime.\n" +"To do this, we will have to rule out things like §1\n" +"We will do this by proving that any factor of §2 is at most §3,\n" +"which we will do using this lemma. The proof I have in mind manipulates the hypothesis\n" +"until it becomes the goal, using §4, §5 and\n" +"§6." +msgstr "" +"Um dia este jogo vai ter um Mundo dos Números Primos, com um chefão final\n" +"que é provar que §0 é primo.\n" +"Para isso, vamos ter que descartar coisas como §1\n" +"Vamos fazer isso provando que qualquer fator de §2 é no máximo §3,\n" +"o que faremos usando este lema. A prova que tenho em mente manipula a hipótese\n" +"até ela virar o objetivo, usando §4, §5 e\n" +"§6." + +#. §0: `False` +#. §1: `True` +#. §2: `is_zero (succ a)` +#. §3: `rw [← is_zero_succ a]` +#: Game.Levels.Algorithm.L06is_zero +msgid "" +"We're going to change that §0 into §1. Start by changing it into\n" +"§2 by executing §3." +msgstr "" +"Vamos trocar esse §0 por §1. Comece transformando-o em\n" +"§2 executando §3." + +#. §0: `contrapose! h` +#: Game.Levels.Algorithm.L07succ_ne_succ +msgid "" +"Can you take it from here? (note: if you try §0 again, it will\n" +"take you back to where you started!)" +msgstr "" +"Consegue seguir daqui? (nota: se você tentar §0 de novo, ele vai\n" +"te levar de volta para onde você começou!)" + +#. §0: `pow_two a` +#. §1: `a ^ 2 = a * a` +#: Game.Levels.Power.L05pow_two +msgid "§0 says that §1." +msgstr "§0 diz que §1." + +#: Game.Levels.Implication.L04succ_inj +msgid "In the next level, we'll do the same proof but backwards." +msgstr "No próximo nível, faremos a mesma prova, mas de trás para frente." + +#. §0: ``` +#. rw [mul_comm, mul_add] +#. repeat rw [mul_comm c] +#. rfl +#. ``` +#: Game.Levels.Multiplication.L08add_mul Game.Levels.LessOrEqual.L09succ_le_succ +msgid "" +"Here's my proof:\n" +"§0" +msgstr "" +"Aqui está a minha prova:\n" +"§0" + +#. §0: `exact` +#: Game.Levels.Implication.L03apply +msgid "Now finish using the §0 tactic." +msgstr "Agora termine usando a tática §0." + +#. §0: `37 ^ n` +#. §1: `37 ^ 0` +#. §2: `37 ^ (succ d)` +#. §3: `37 ^ d` +#. §4: `pow_zero (a : ℕ) : a ^ 0 = 1` +#. §5: `pow_succ (a b : ℕ) : a ^ succ b = a ^ b * a` +#: Game.Levels.Power +msgid "" +"This world introduces exponentiation. If you want to define §0\n" +"then, as always, you will need to know what §1 is, and\n" +"what §2 is, given only §3.\n" +"\n" +"You can probably guess the names of the general theorems:\n" +"\n" +" * §4\n" +" * §5\n" +"\n" +"Using only these, can you get past the final boss level?\n" +"\n" +"The levels in this world were designed by Sian Carey, a UROP student\n" +"at Imperial College London, funded by a Mary Lister McCammon Fellowship\n" +"in the summer of 2019. Thanks to Sian and also thanks to Imperial\n" +"College for funding her." +msgstr "" +"Este mundo apresenta a exponenciação. Se você quiser definir §0\n" +"então, como sempre, vai precisar saber o que é §1, e\n" +"o que é §2, dado apenas §3.\n" +"\n" +"Você provavelmente consegue adivinhar os nomes dos teoremas gerais:\n" +"\n" +" * §4\n" +" * §5\n" +"\n" +"Usando apenas esses, você consegue passar do chefão final?\n" +"\n" +"Os níveis deste mundo foram criados por Sian Carey, estudante de UROP\n" +"no Imperial College London, financiada por uma Mary Lister McCammon Fellowship\n" +"no verão de 2019. Obrigado à Sian e também ao Imperial College por\n" +"financiá-la." + +#. §0: `h` +#. §1: `succ x = succ 3` +#. §2: `succ_inj` +#. §3: `rw [four_eq_succ_three] at h` +#: Game.Levels.Implication.L04succ_inj +msgid "" +"Let's first get §0 into the form §1 so we can\n" +"apply §2. First execute §3\n" +"to change the 4 on the right hand side." +msgstr "" +"Vamos primeiro colocar §0 na forma §1 para podermos\n" +"aplicar §2. Primeiro execute §3\n" +"para mudar o 4 do lado direito." + +#. §0: `rw [← two_eq_succ_one]` +#. §1: `succ 1` +#. §2: `2` +#: Game.Levels.Tutorial.L04rw_backwards Game.Levels.Tutorial.L05add_zero +msgid "Now §0 will change §1 into §2." +msgstr "Agora §0 vai transformar §1 em §2." + +#. §0: ``` +#. intro h +#. apply succ_inj +#. repeat rw [succ_eq_add_one] +#. exact h +#. ``` +#: Game.Levels.Implication.L07intro2 +msgid "" +"Here's a completely backwards proof:\n" +"§0" +msgstr "" +"Aqui está uma prova completamente de trás para frente:\n" +"§0" + +#: Game.Levels.LessOrEqual.L05le_zero +msgid "x ≤ 0 → x = 0" +msgstr "x ≤ 0 → x = 0" + +#: Game.Levels.AdvAddition +msgid "Advanced Addition World" +msgstr "Mundo da Adição Avançada" + +#. §0: $x$ +#. §1: $q$ +#. §2: $37x+q=37x+q.$ +#: Game.Levels.Tutorial.L01rfl +msgid "If §0 and §1 are arbitrary natural numbers, then §2" +msgstr "Se §0 e §1 são números naturais arbitrários, então §2" + +#. §0: `left` +#: Game.Levels.LessOrEqual.L07or_symm +msgid "This time, use the §0 tactic." +msgstr "Desta vez, use a tática §0." + +#. §0: $(a+b)^2=a^2+b^2$ +#: Game.Levels.Power.L09add_sq +msgid "" +"It's all over! You have proved a theorem which has tripped up\n" +"schoolkids for generations (some of them think §0:\n" +"this is \"the freshman's dream\").\n" +"\n" +"How many rewrites did you use? I can do it in 12.\n" +"\n" +"But wait! This boss is stirring...and mutating into a second more powerful form!" +msgstr "" +"Acabou! Você provou um teorema que derrubou\n" +"gerações de estudantes (alguns deles acham que §0:\n" +"esse é o \"sonho do calouro\").\n" +"\n" +"Quantas reescritas você usou? Eu consigo em 12.\n" +"\n" +"Mas espere! Este chefão está se mexendo... e se transformando numa segunda forma mais poderosa!" + +#. §0: $a$ +#. §1: $b$ +#. §2: $c$ +#. §3: $(a + b) \\times c = ac + bc$ +#: Game.Levels.Multiplication.L08add_mul +msgid "" +"Addition is distributive over multiplication.\n" +"In other words, for all natural numbers §0, §1 and §2, we have\n" +"§3." +msgstr "" +"A adição é distributiva sobre a multiplicação.\n" +"Em outras palavras, para quaisquer números naturais §0, §1 e §2, temos\n" +"§3." + +#. §0: `one_mul m` +#. §1: `1 * m = m` +#: Game.Levels.Multiplication.L05one_mul +msgid "§0 is the proof §1." +msgstr "§0 é a prova de §1." + +#: Game.Levels.Algorithm.L03add_algo2 +msgid "making life simple" +msgstr "simplificando a vida" + +#. §0: `four_eq_succ_three` +#: Game.Levels.Implication.L05succ_inj2 +msgid "" +"Now rewrite §0 backwards to make the goal\n" +"equal to the hypothesis." +msgstr "" +"Agora reescreva §0 de trás para frente para deixar o objetivo\n" +"igual à hipótese." + +#: Game.Levels.Addition.L04add_assoc +msgid "add_assoc (associativity of addition)" +msgstr "add_assoc (associatividade da adição)" + +#. §0: `add_assoc a b c` +#. §1: `(a + b) + c = a + (b + c)` +#. §2: `(a + b) + c` +#. §3: `a + b + c` +#: Game.Levels.Addition.L04add_assoc +msgid "" +"§0 is a proof\n" +"that §1. Note that in Lean §2 prints\n" +"as §3, because the notation for addition is defined to be left\n" +"associative." +msgstr "" +"§0 é uma prova\n" +"de que §1. Note que no Lean §2 aparece\n" +"como §3, porque a notação para adição é definida como associativa\n" +"à esquerda." + +#. §0: `intro h` +#: Game.Levels.Implication.L07intro2 +msgid "Start with §0 to assume the hypothesis." +msgstr "Comece com §0 para supor a hipótese." + +#: Game.Levels.Multiplication.L04mul_comm +msgid "mul_comm" +msgstr "mul_comm" + +#. §0: `2 + 2 ≠ 5` +#: Game.Levels.Algorithm.L09decide2 +msgid "We gave a pretty unsatisfactory proof of §0 earlier on; now give a nicer one." +msgstr "Demos uma prova bem insatisfatória de §0 lá atrás; agora dê uma mais bonita." + +#. §0: $n = 0$ +#. §1: `X = Y` +#: Game.Levels.Addition.L01zero_add +msgid "" +"Now you have two goals. Once you proved the first, you will jump to the second one.\n" +"This first goal is the base case §0.\n" +"\n" +"Recall that you can rewrite the proof of any lemma which is visible\n" +"in your inventory, or of any assumption displayed above the goal,\n" +"as long as it is of the form §1." +msgstr "" +"Agora você tem dois objetivos. Assim que provar o primeiro, você pula para o segundo.\n" +"Este primeiro objetivo é o caso base §0.\n" +"\n" +"Lembre que você pode reescrever a prova de qualquer lema que esteja visível\n" +"no seu inventário, ou de qualquer hipótese exibida acima do objetivo,\n" +"desde que ela seja da forma §1." + +#. §0: `x + 1 = 4` +#. §1: `x = 3` +#. §2: `apply` +#: Game.Levels.Implication.L05succ_inj2 +msgid "" +"In the last level, we manipulated the hypothesis §0\n" +" until it became the goal §1. In this level we'll manipulate\n" +" the goal until it becomes our hypothesis! In other words, we\n" +" will \"argue backwards\". The §2 tactic can do this too.\n" +" Again I will walk you through this one (assuming you're in\n" +" command line mode)." +msgstr "" +"No nível anterior, manipulamos a hipótese §0\n" +" até ela virar o objetivo §1. Neste nível vamos manipular\n" +" o objetivo até ele virar a nossa hipótese! Em outras palavras, vamos\n" +" \"argumentar de trás para frente\". A tática §2 também consegue fazer isso.\n" +" De novo, vou te guiar por este (supondo que você esteja no\n" +" modo linha de comando)." + +#. §0: `add_zero c` +#. §1: `c + 0 = c` +#. §2: `b + 0` +#. §3: `b` +#. §4: `rw [add_zero]` +#. §5: `rw [add_zero b]` +#. §6: `rw [add_zero]` +#: Game.Levels.Tutorial.L06add_zero2 +msgid "" +"§0 is a proof of §1 so that was what got rewritten.\n" +"You can now change §2 to §3 with §4 or §5. You\n" +"can usually stick to §6 unless you need real precision." +msgstr "" +"§0 é uma prova de §1, então foi isso que foi reescrito.\n" +"Agora você pode mudar §2 para §3 com §4 ou §5. Em geral você\n" +"pode ficar com §6, a menos que precise de precisão de verdade." + +#: Game.Levels.AdvAddition.L01add_right_cancel +msgid "add_right_cancel" +msgstr "add_right_cancel" + +#. §0: `succ_eq_add_one` +#. §1: `h` +#: Game.Levels.Implication.L04succ_inj +msgid "" +"Now rewrite §0 backwards at §1\n" +"to get the right hand side." +msgstr "" +"Agora reescreva §0 de trás para frente em §1\n" +"para obter o lado direito." + +#. §0: `decide` +#: Game.Levels.Algorithm.L08decide +msgid "" +"You can read more about the §0 tactic by clicking\n" +"on it in the top right." +msgstr "" +"Você pode ler mais sobre a tática §0 clicando\n" +"nela no canto superior direito." + +#. §0: `a ≠ b` +#. §1: `(a = b) → False` +#. §2: `P` +#. §3: `P → False` +#. §4: `P` +#. §5: `True → False` +#. §6: `False → False` +#. §7: `a ≠ b` +#. §8: `P → Q` +#. §9: `a ≠ b` +#. §10: `intro h` +#. §11: `h` +#. §12: `a ≠ b` +#. §13: `apply h at h1` +#. §14: `h1` +#. §15: `a = b` +#: Game.Levels.Implication.L08ne +msgid "" +"§0 is *notation* for §1.\n" +"\n" +"The reason this is mathematically\n" +"valid is that if §2 is a true-false statement then §3\n" +"is the logical opposite of §4. Indeed §5 is false,\n" +"and §6 is true!\n" +"\n" +"The upshot of this is that you can treat §7 in exactly\n" +"the same way as you treat any implication §8. For example,\n" +"if your *goal* is of the form §9 then you can make progress\n" +"with §10, and if you have a hypothesis §11 of the\n" +"form §12 then you can §13 if §14 is a proof\n" +"of §15." +msgstr "" +"§0 é uma *notação* para §1.\n" +"\n" +"A razão pela qual isso é matematicamente\n" +"válido é que, se §2 é uma afirmação verdadeiro-falso, então §3\n" +"é o oposto lógico de §4. De fato, §5 é falso,\n" +"e §6 é verdadeiro!\n" +"\n" +"A consequência disso é que você pode tratar §7 exatamente\n" +"da mesma forma que trata qualquer implicação §8. Por exemplo,\n" +"se seu *objetivo* é da forma §9, então você pode progredir\n" +"com §10, e se você tem uma hipótese §11 da\n" +"forma §12, então você pode fazer §13 se §14 for uma prova\n" +"de §15." + +#. §0: `mul_assoc a b c` +#. §1: `(a * b) * c = a * (b * c)` +#. §2: `a * b * c` +#. §3: `(a * b) * c` +#. §4: `(a * b) * c = a * (b * c)` +#. §5: `(6 - 2) - 1` +#. §6: `6 - (2 - 1)` +#: Game.Levels.Multiplication.L09mul_assoc +msgid "" +"§0 is a proof that §1.\n" +"\n" +"Note that when Lean says §2 it means §3.\n" +"\n" +"Note that §4 cannot be proved by \\\\\"pure thought\\\\\":\n" +"for example subtraction is not associative, as §5 is not\n" +"equal to §6." +msgstr "" +"§0 é uma prova de que §1.\n" +"\n" +"Note que, quando Lean escreve §2, ele quer dizer §3.\n" +"\n" +"Note que §4 não pode ser provado por \\\\\"puro pensamento\\\\\":\n" +"por exemplo, a subtração não é associativa, pois §5 não é\n" +"igual a §6." + +#: Game.Levels.AdvAddition.L03add_left_eq_self +msgid "add_left_eq_self" +msgstr "add_left_eq_self" + +#: GameServer.RpcHandlers +msgid "level completed with warnings… 🎭" +msgstr "nível completado com avisos… 🎭" + +#. §0: `h2` +#. §1: `x = y → False` +#. §2: `apply` +#. §3: `h2` +#. §4: `at h1` +#: Game.Levels.Implication.L08ne +msgid "" +"Remember that §0 is a proof of §1. Try\n" +"§2ing §3 either §4 or directly to the goal." +msgstr "" +"Lembre que §0 é uma prova de §1. Tente\n" +"usar §2 com §3, seja §4 ou diretamente no objetivo." + +#. §0: `apply mul_left_cancel at h` +#: Game.Levels.AdvMultiplication.L10mul_right_eq_self +msgid "You can now §0" +msgstr "Agora você pode §0" + +#. §0: `x * y = 1 → x = 1` +#. §1: `x + y = 0 → x = 0` +#. §2: `x ≤ 1` +#. §3: `le_one` +#. §4: `≤` +#. §5: `have` +#: Game.Levels.AdvMultiplication.L06mul_right_eq_one +msgid "" +"This level proves §0, the multiplicative analogue of Advanced Addition\n" +"World's §1. The strategy is to prove that §2 and then use the\n" +"lemma §3 from §4 world.\n" +"\n" +"We'll prove it using a new and very useful tactic called §5." +msgstr "" +"Este nível prova §0, o análogo multiplicativo do §1 do Mundo da\n" +"Adição Avançada. A estratégia é provar que §2 e então usar o\n" +"lema §3 do mundo §4.\n" +"\n" +"Vamos prová-lo usando uma nova e muito útil tática chamada §5." + +#: Game.Levels.Power.L06pow_add +msgid "pow_add" +msgstr "pow_add" + +#. §0: `rw [add_zero c]` +#: Game.Levels.Tutorial.L06add_zero2 Game.Levels.LessOrEqual.L08le_total +msgid "Try §0." +msgstr "Tente §0." + +#. §0: `{0,1,2,3,4,...}` +#. §1: `2 + 2 = 4` +#. §2: `x + y = y + x` +#: Game +msgid "" +"# Welcome to the Natural Number Game\n" +"#### An introduction to mathematical proof.\n" +"\n" +"In this game, we will build the basic theory of the natural\n" +"numbers §0 from scratch. Our first goal is to prove\n" +"that §1. Next we'll prove that §2.\n" +"And at the end we'll see if we can prove Fermat's Last Theorem.\n" +"We'll do this by solving levels of a computer puzzle game called Lean.\n" +"\n" +"# Read this.\n" +"\n" +"Learning how to use an interactive theorem prover takes time.\n" +"Tests show that the people who get the most out of this game are\n" +"those who read the help texts like this one.\n" +"\n" +"To start, click on \"Tutorial World\".\n" +"\n" +"Note: this is a new Lean 4 version of the game containing several\n" +"worlds which were not present in the old Lean 3 version. More new worlds\n" +"such as Strong Induction World, Even/Odd World and Prime Number World\n" +"are in development; if you want to see their state or even help out, checkout\n" +"out the [issues in the github repo](https://github.com/leanprover-community/NNG4/issues).\n" +"\n" +"## More\n" +"\n" +"Click on the three lines in the top right and select \"Game Info\" for resources,\n" +"links, and ways to interact with the Lean community." +msgstr "" +"# Bem-vindo ao Jogo dos Números Naturais\n" +"#### Uma introdução à prova matemática.\n" +"\n" +"Neste jogo, vamos construir do zero a teoria básica dos números\n" +"naturais §0. Nosso primeiro objetivo é provar\n" +"que §1. Depois vamos provar que §2.\n" +"E no final vamos ver se conseguimos provar o Último Teorema de Fermat.\n" +"Faremos isso resolvendo níveis de um jogo de quebra-cabeça de computador chamado Lean.\n" +"\n" +"# Leia isto.\n" +"\n" +"Aprender a usar um provador de teoremas interativo leva tempo.\n" +"Testes mostram que as pessoas que mais aproveitam este jogo são\n" +"aquelas que leem os textos de ajuda como este.\n" +"\n" +"Para começar, clique em \"Mundo Tutorial\".\n" +"\n" +"Nota: esta é uma nova versão do jogo em Lean 4, contendo vários\n" +"mundos que não existiam na antiga versão em Lean 3. Novos mundos,\n" +"como o Mundo da Indução Forte, o Mundo dos Pares e Ímpares e o Mundo dos Números Primos,\n" +"estão em desenvolvimento; se você quiser ver o estado deles ou até ajudar, dê uma olhada\n" +"nas [issues no repositório do github](https://github.com/leanprover-community/NNG4/issues).\n" +"\n" +"## Mais\n" +"\n" +"Clique nas três linhas no canto superior direito e selecione \"Informações do jogo\" para recursos,\n" +"links e formas de interagir com a comunidade Lean." + +#. §0: $a$ +#. §1: $a ^ 1 = a$ +#: Game.Levels.Power.L03pow_one Game.Levels.Power.L04one_pow Game.Levels.Power.L05pow_two +msgid "For all naturals §0, §1." +msgstr "Para quaisquer naturais §0, §1." + +#. §0: `decide` +#. §1: `DecidableEq ℕ` +#. §2: `instance` +#. §3: `decide` +#. §4: `a = b` +#. §5: `a ≠ b` +#: Game.Levels.Algorithm.L08decide +msgid "" +"# Summary\n" +"\n" +"§0 will attempt to solve a goal if it can find an algorithm which it\n" +"can run to solve it.\n" +"\n" +"## Example\n" +"\n" +"A term of type §1 is an algorithm to decide whether two naturals\n" +"are equal or different. Hence, once this term is made and made into an §2,\n" +"the §3 tactic can use it to solve goals of the form §4 or §5." +msgstr "" +"# Resumo\n" +"\n" +"§0 vai tentar resolver um objetivo se conseguir encontrar um algoritmo que\n" +"possa executar para resolvê-lo.\n" +"\n" +"## Exemplo\n" +"\n" +"Um termo do tipo §1 é um algoritmo para decidir se dois naturais\n" +"são iguais ou diferentes. Portanto, uma vez que esse termo seja construído e transformado numa §2,\n" +"a tática §3 pode usá-lo para resolver objetivos da forma §4 ou §5." + +#. §0: `apply` +#. §1: `apply succ_inj at h` +#. §2: `h` +#. §3: `x = 3` +#: Game.Levels.Implication.L04succ_inj +msgid "" +"Now let's §0 our new theorem. Execute §1\n" +"to change §2 to a proof of §3." +msgstr "" +"Agora vamos usar §0 no nosso novo teorema. Execute §1\n" +"para transformar §2 numa prova de §3." + +#. §0: `repeat t` +#. §1: `t` +#. §2: `repeat rw [add_zero]` +#. §3: `a + 0 + (0 + (0 + 0)) = b + 0 + 0` +#. §4: `a = b` +#. §5: `h : X = Y` +#. §6: `X` +#. §7: `nth_rewrite 3 [h]` +#. §8: `X` +#. §9: `Y` +#. §10: `2 + 2 = 4` +#. §11: `nth_rewrite 2 [two_eq_succ_one]` +#. §12: `2 + succ 1 = 4` +#. §13: `rw [two_eq_succ_one]` +#. §14: `succ 1 + succ 1 = 4` +#: Game.Levels.Tutorial.L02rw +msgid "" +"## Summary\n" +"\n" +"§0 repeatedly applies the tactic §1\n" +"to the goal. You don't need to use this\n" +"tactic, it just speeds things up sometimes.\n" +"\n" +"## Example\n" +"\n" +"§2 will turn the goal\n" +"§3\n" +"into the goal\n" +"§4.\n" +"\"\n" +"\n" +"TacticDoc nth_rewrite \"\n" +"## Summary\n" +"\n" +"If §5 and there are several §6s in the goal, then\n" +"§7 will just change the third §8 to a §9.\n" +"\n" +"## Example\n" +"\n" +"If the goal is §10 then §11\n" +"will change the goal to §12. In contrast, §13\n" +"will change the goal to §14." +msgstr "" +"## Resumo\n" +"\n" +"§0 aplica repetidamente a tática §1\n" +"ao objetivo. Você não precisa usar essa\n" +"tática, ela só acelera as coisas às vezes.\n" +"\n" +"## Exemplo\n" +"\n" +"§2 vai transformar o objetivo\n" +"§3\n" +"no objetivo\n" +"§4.\n" +"\"\n" +"\n" +"TacticDoc nth_rewrite \"\n" +"## Resumo\n" +"\n" +"Se §5 e há vários §6s no objetivo, então\n" +"§7 vai mudar apenas o terceiro §8 para um §9.\n" +"\n" +"## Exemplo\n" +"\n" +"Se o objetivo é §10 então §11\n" +"vai mudar o objetivo para §12. Em contraste, §13\n" +"vai mudar o objetivo para §14." + +#: Game.Levels.Tutorial.L01rfl +msgid "The rfl tactic" +msgstr "A tática rfl" + +#. §0: ``` +#. macro \"simp_add\" : tactic => `(tactic|( +#. simp only [add_assoc, add_left_comm, add_comm])) +#. ``` +#. §1: `simp_add` +#. §2: `simp only [add_assoc, add_left_comm, add_comm]` +#. §3: `simp_add` +#: Game.Levels.Algorithm.L04add_algo3 +msgid "" +"You can make your own tactics in Lean.\n" +"This code here\n" +"§0\n" +"was used to create a new tactic §1, which runs\n" +"§2.\n" +"Try running §3 to solve this level!" +msgstr "" +"Você pode criar suas próprias táticas em Lean.\n" +"Este código aqui\n" +"§0\n" +"foi usado para criar uma nova tática §1, que executa\n" +"§2.\n" +"Tente executar §3 para resolver este nível!" + +#. §0: $x \\leq 1$ +#. §1: $x = 0$ +#. §2: $x = 1$ +#: Game.Levels.LessOrEqual.L10le_one +msgid "If §0 then either §1 or §2." +msgstr "Se §0 então §1 ou §2." + +#: Game.Levels.Addition.L02succ_add +msgid "succ_add" +msgstr "succ_add" + +#. §0: `rw [zero_add] at «{h}»` +#. §1: `zero_add` +#. §2: `«{x}»` +#. §3: `0 + «{x}»` +#. §4: `0 + «{y}»` +#: Game.Levels.Implication.L02exact2 +msgid "" +"Do that again!\n" +"\n" +"§0 tries to fill in\n" +"the arguments to §1 (finding §2) then it replaces all occurrences of\n" +"§3 it finds. Therefor, it did not rewrite §4, yet." +msgstr "" +"Faça isso de novo!\n" +"\n" +"§0 tenta preencher\n" +"os argumentos de §1 (encontrando §2) e então substitui todas as ocorrências de\n" +"§3 que encontrar. Portanto, ele ainda não reescreveu §4." + +#. §0: `a` +#. §1: `b` +#. §2: `c` +#: Game.Levels.Multiplication.L07mul_add +msgid "" +"Induction on §0 is the most troublesome, then §1,\n" +"and §2 is the easiest." +msgstr "" +"A indução em §0 é a mais trabalhosa, depois §1,\n" +"e §2 é a mais fácil." + +#. §0: $a+(b+0)+(c+0)=a+b+c.$ +#: Game.Levels.Tutorial.L05add_zero Game.Levels.Tutorial.L06add_zero2 Game.Levels.Power.L01zero_pow_zero +#: Game.Levels.Algorithm.L09decide2 Game.Levels.AdvAddition.L03add_left_eq_self +msgid "§0" +msgstr "§0" + +#. §0: `zero_ne_succ` +#. §1: `succ_inj` +#: Game.Levels.Implication.L11two_add_two_ne_five +msgid "" +"2 + 2 ≠ 5 is boring to prove in full, given only the tools we have currently.\n" +"To make it a bit less painful, I have unfolded all of the numerals for you.\n" +"See if you can use §0 and §1 to prove this." +msgstr "" +"2 + 2 ≠ 5 é chato de provar por completo, dadas apenas as ferramentas que temos no momento.\n" +"Para deixar isso um pouco menos doloroso, eu já desdobrei todos os numerais para você.\n" +"Veja se você consegue usar §0 e §1 para provar isso." + +#. §0: $x$ +#. §1: $y$ +#. §2: $x \\leq y$ +#. §3: $y \\leq x$ +#: Game.Levels.LessOrEqual.L08le_total +msgid "If §0 and §1 are numbers, then either §2 or §3." +msgstr "Se §0 e §1 são números, então §2 ou §3." + +#. §0: `a ≤ b` +#. §1: `a ≤ b` +#. §2: `b ≤ c` +#. §3: `a ≤ c` +#. §4: `a ≤ b` +#. §5: `c` +#. §6: `b = a + c` +#: Game.Levels.LessOrEqual +msgid "" +"In this world we define §0 and prove standard facts\n" +"about it, such as \"if §1 and §2 then §3.\"\n" +"\n" +"The definition of §4 is \"there exists a number §5\n" +"such that §6. \" So we're going to have to learn\n" +"a tactic to prove \"exists\" theorems, and another one\n" +"to use \"exists\" hypotheses.\n" +"\n" +"Click on \"Start\" to proceed." +msgstr "" +"Neste mundo definimos §0 e provamos fatos padrão\n" +"sobre isso, como \"se §1 e §2 então §3.\"\n" +"\n" +"A definição de §4 é \"existe um número §5\n" +"tal que §6. \" Então vamos ter que aprender\n" +"uma tática para provar teoremas de \"existe\", e outra\n" +"para usar hipóteses de \"existe\".\n" +"\n" +"Clique em \"Começar\" para prosseguir." + +#: Game +msgid "" +"*Game version: 4.3*\n" +"\n" +"*Recent additions: bug fixes*\n" +"\n" +"## Progress saving\n" +"\n" +"The game stores your progress in your local browser storage.\n" +"If you delete it, your progress will be lost!\n" +"\n" +"Warning: In most browsers, deleting cookies will also clear the local storage\n" +"(or \"local site data\"). Make sure to download your game progress first!\n" +"\n" +"## Credits\n" +"\n" +"* **Creators:** Kevin Buzzard, Jon Eugster\n" +"* **Original Lean3-version:** Kevin Buzzard, Mohammad Pedramfar\n" +"* **Game Engine:** Alexander Bentkamp, Jon Eugster, Patrick Massot\n" +"* **Additional levels:** Sian Carey, Ivan Farabella, Archie Browne.\n" +"* **Additional thanks:** All the student beta testers, all the schools\n" +"who invited Kevin to speak, and all the schoolkids who asked him questions\n" +"about the material.\n" +"\n" +"## Resources\n" +"\n" +"* The [Lean Zulip chat](https://leanprover.zulipchat.com/) forum\n" +"* [Original Lean3 version](https://www.ma.imperial.ac.uk/~buzzard/xena/natural_number_game/) (no longer " +"maintained)\n" +"\n" +"## Problems?\n" +"\n" +"Please ask any questions about this game in the\n" +"[Lean Zulip chat](https://leanprover.zulipchat.com/) forum, for example in\n" +"the stream \"New Members\". The community will happily help. Note that\n" +"the Lean Zulip chat is a professional research forum.\n" +"Please use your full real name there, stay on topic, and be nice. If you're\n" +"looking for somewhere less formal (e.g. you want to post natural number\n" +"game memes) then head on over to the [Lean Discord](https://discord.gg/WZ9bs9UCvx).\n" +"\n" +"Alternatively, if you experience issues / bugs you can also open github issues:\n" +"\n" +"* For issues with the game engine, please open an\n" +"[issue at the lean4game](https://github.com/leanprover-community/lean4game/issues) repo.\n" +"* For issues about the game's content, please open an\n" +"[issue at the NNG](https://github.com/hhu-adam/NNG4/issues) repo." +msgstr "" +"*Versão do jogo: 4.3*\n" +"\n" +"*Adições recentes: correções de bugs*\n" +"\n" +"## Salvamento do progresso\n" +"\n" +"O jogo guarda seu progresso no armazenamento local do seu navegador.\n" +"Se você apagá-lo, seu progresso será perdido!\n" +"\n" +"Atenção: na maioria dos navegadores, apagar os cookies também limpa o armazenamento local\n" +"(ou \"dados locais do site\"). Certifique-se de baixar seu progresso antes!\n" +"\n" +"## Créditos\n" +"\n" +"* **Criadores:** Kevin Buzzard, Jon Eugster\n" +"* **Versão original em Lean3:** Kevin Buzzard, Mohammad Pedramfar\n" +"* **Engine do jogo:** Alexander Bentkamp, Jon Eugster, Patrick Massot\n" +"* **Níveis adicionais:** Sian Carey, Ivan Farabella, Archie Browne.\n" +"* **Tradução para Português Brasileiro:** Luís Felipe Marques.\n" +"* **Agradecimentos adicionais:** Todos os estudantes beta testers, todas as escolas\n" +"que convidaram Kevin para palestrar, e todos os alunos que lhe fizeram perguntas\n" +"sobre o material.\n" +"\n" +"## Recursos\n" +"\n" +"* O fórum [Lean Zulip chat](https://leanprover.zulipchat.com/)\n" +"* [Versão original em Lean3](https://www.ma.imperial.ac.uk/~buzzard/xena/natural_number_game/) (não " +"mantida mais)\n" +"\n" +"## Problemas?\n" +"\n" +"Por favor, faça qualquer pergunta sobre este jogo no fórum\n" +"[Lean Zulip chat](https://leanprover.zulipchat.com/), por exemplo no\n" +"canal \"New Members\". A comunidade vai ajudar com prazer. Note que\n" +"o Lean Zulip chat é um fórum profissional de pesquisa.\n" +"Por favor, use seu nome real completo lá, mantenha-se no tema e seja gentil. Se você\n" +"procura algo menos formal (por exemplo, se quiser postar memes do jogo dos números\n" +"naturais), então vá para o [Discord do Lean](https://discord.gg/WZ9bs9UCvx).\n" +"\n" +"Alternativamente, se você encontrar problemas / bugs, também pode abrir issues no github:\n" +"\n" +"* Para problemas com o motor do jogo, por favor abra uma\n" +"[issue no repositório do lean4game](https://github.com/leanprover-community/lean4game/issues).\n" +"* Para problemas com o conteúdo do jogo, por favor abra uma\n" +"[issue no repositório do NNG](https://github.com/hhu-adam/NNG4/issues)." + +#. §0: $a$ +#. §1: $m$ +#. §2: $n$ +#. §3: $a^{m + n} = a ^ m a ^ n$ +#: Game.Levels.Power.L06pow_add Game.Levels.Power.L07mul_pow Game.Levels.Power.L08pow_pow +msgid "For all naturals §0, §1, §2, we have §3." +msgstr "Para quaisquer naturais §0, §1, §2, temos §3." + +#. §0: ```lean +#. nth_rewrite 2 [two_eq_succ_one] -- only change the second `2` to `succ 1`. +#. rw [add_succ] +#. rw [one_eq_succ_zero] +#. rw [add_succ, add_zero] -- two rewrites at once +#. rw [← three_eq_succ_two] -- change `succ 2` to `3` +#. rw [← four_eq_succ_three] +#. rfl +#. ``` +#. §1: `` +#. §2: `>_` +#. §3: `induction` +#: Game.Levels.Tutorial.L08twoaddtwo +msgid "" +"Here is an example proof of 2+2=4 showing off various techniques.\n" +"\n" +"§0\n" +"\n" +"Optional extra: you can run this proof yourself. Switch the game into \"Editor mode\" by clicking\n" +"on the §1 button in the top right. You can now see your proof\n" +"written as several lines of code. Move your cursor between lines to see\n" +"the goal state at any point. Now cut and paste your code elsewhere if you\n" +"want to save it, and paste the above proof in instead. Move your cursor\n" +"around to investigate. When you've finished, click the §2 button in the top right to\n" +"move back into \"Typewriter mode\".\n" +"\n" +"You have finished tutorial world!\n" +"Click \"Leave World\" to go back to the\n" +"overworld, and select Addition World, where you will learn\n" +"about the §3 tactic." +msgstr "" +"Aqui está um exemplo de prova de 2+2=4 mostrando várias técnicas.\n" +"\n" +"§0\n" +"\n" +"Extra opcional: você pode rodar essa prova você mesmo. Mude o jogo para o \"Modo editor\" clicando\n" +"no botão §1 no canto superior direito. Agora você pode ver sua prova\n" +"escrita como várias linhas de código. Mova o cursor entre as linhas para ver\n" +"o estado do objetivo em qualquer ponto. Agora recorte e cole seu código em outro lugar se\n" +"quiser salvá-lo, e cole a prova acima no lugar. Mova o cursor\n" +"para investigar. Quando terminar, clique no botão §2 no canto superior direito para\n" +"voltar ao \"Modo máquina de escrever\".\n" +"\n" +"Você terminou o mundo tutorial!\n" +"Clique em \"Leave World\" para voltar ao\n" +"mapa geral, e selecione o Mundo da Adição, onde você vai aprender\n" +"sobre a tática §3." + +#: Game.Levels.AdvMultiplication.L09mul_left_cancel +msgid "mul_left_cancel" +msgstr "mul_left_cancel" + +#: Game.Levels.AdvAddition.L06add_left_eq_zero +msgid "" +"You can just mimic the previous proof to do this one -- or you can figure out a way\n" +"of using it." +msgstr "" +"Você pode simplesmente imitar a prova anterior para fazer esta -- ou pode descobrir um jeito\n" +"de usá-la." + +#. §0: `0` +#. §1: `n` +#. §2: `succ n` +#. §3: `n` +#. §4: `n` +#. §5: `n` +#. §6: `0` +#. §7: `succ 0` +#. §8: `1` +#. §9: `2 = succ 1` +#. §10: `3 = succ 2` +#. §11: `4 = succ 3` +#. §12: `2 = succ 1` +#. §13: `two_eq_succ_one` +#. §14: $2$ +#: Game.Levels.Tutorial.L03two_eq_ss0 +msgid "" +"## The birth of number.\n" +"\n" +"Numbers in Lean are defined by two rules.\n" +"\n" +"* §0 is a number.\n" +"* If §1 is a number, then the *successor* §2 of §3 is a number.\n" +"\n" +"The successor of §4 means the number after §5. Let's learn to\n" +"count, and name a few small numbers.\n" +"\n" +"## Counting to four.\n" +"\n" +"§6 is a number, so §7 is a number. Let's call this new number §8.\n" +"Similarly let's define §9, §10 and §11.\n" +"This gives us plenty of numbers to be getting along with.\n" +"\n" +"The *proof* that §12 is called §13.\n" +"Check out the \"012\" tab in the list of lemmas on the right\n" +"for this and other proofs.\n" +"\n" +"Let's prove that §14 is the number after the number after zero." +msgstr "" +"## O nascimento do número.\n" +"\n" +"Os números em Lean são definidos por duas regras.\n" +"\n" +"* §0 é um número.\n" +"* Se §1 é um número, então o *sucessor* §2 de §3 é um número.\n" +"\n" +"O sucessor de §4 significa o número depois de §5. Vamos aprender a\n" +"contar e dar nome a alguns números pequenos.\n" +"\n" +"## Contando até quatro.\n" +"\n" +"§6 é um número, então §7 é um número. Vamos chamar esse novo número de §8.\n" +"Do mesmo jeito, vamos definir §9, §10 e §11.\n" +"Isso já nos dá bastante números para trabalhar.\n" +"\n" +"A *prova* de que §12 se chama §13.\n" +"Dê uma olhada na aba \"012\" na lista de lemas à direita\n" +"para ver essa e outras provas.\n" +"\n" +"Vamos provar que §14 é o número depois do número depois do zero." + +#. §0: `rw [← succ_eq_add_one] at h` +#: Game.Levels.Implication.L04succ_inj +msgid "Concretely: §0." +msgstr "Concretamente: §0." + +#. §0: `pow_zero a : a ^ 0 = 1` +#: Game.Levels.Power.L01zero_pow_zero +msgid "" +"§0 is one of the two axioms\n" +"defining exponentiation in this game." +msgstr "" +"§0 é um dos dois axiomas\n" +"que definem a exponenciação neste jogo." + +#. §0: $a, b$ +#. §1: $c$ +#. §2: $(a + b) + c = (a + c) + b$ +#: Game.Levels.Addition.L05add_right_comm +msgid "" +"If §0 and §1 are arbitrary natural numbers, we have\n" +"§2." +msgstr "" +"Se §0 e §1 são números naturais arbitrários, temos\n" +"§2." + +#: Game.Levels.AdvMultiplication.L10mul_right_eq_self +msgid "" +"The lemma proved in the final level of this world will be helpful\n" +"in Divisibility World." +msgstr "" +"O lema provado no nível final deste mundo vai ser útil\n" +"no Mundo da Divisibilidade." + +#. §0: `pow_one a` +#. §1: `a ^ 1 = a` +#. §2: `a ^ 1` +#. §3: `a ^ 0 * a` +#. §4: `1 * a` +#. §5: `a` +#: Game.Levels.Power.L03pow_one +msgid "" +"§0 says that §1.\n" +"\n" +"Note that this is not quite true by definition: §2 is\n" +"defined to be §3 so it's §4, and to prove\n" +"that this is equal to §5 you need to use induction somewhere." +msgstr "" +"§0 diz que §1.\n" +"\n" +"Repare que isso não é bem verdade por definição: §2 é\n" +"definido como §3, ou seja, é §4, e para provar\n" +"que isso é igual a §5 você precisa usar indução em algum momento." + +#. §0: `add_right_eq_self x y` +#. §1: $x + y = x\\implies y=0.$ +#: Game.Levels.AdvAddition.L04add_right_eq_self +msgid "" +"§0 is the theorem that §1\n" +"Two ways to do it spring to mind; I'll mention them when you've solved it." +msgstr "" +"§0 é o teorema de que §1\n" +"Duas maneiras de fazer isso me vêm à cabeça; vou mencioná-las quando você resolver." + +#. §0: $2+2=4$ +#. §1: $a+b+c+d+e=e+d+c+b+a$ +#: Game.Levels.Algorithm +msgid "" +"Proofs like §0 and §1 are very tedious to do by hand.\n" +"In Algorithm World we learn how to get the computer to do them for us.\n" +"\n" +"Click on \"Start\" to proceed." +msgstr "" +"Provas como §0 e §1 são bem tediosas de fazer na mão.\n" +"No Mundo dos Algoritmos aprendemos como fazer o computador fazê-las por nós.\n" +"\n" +"Clique em \"Começar\" para continuar." + +#: Game.Levels.Implication.L02exact2 +msgid "" +"If the goal is not *exactly* a hypothesis, we can sometimes\n" +"use rewrites to fix things up." +msgstr "" +"Se o objetivo não é *exatamente* uma hipótese, às vezes podemos\n" +"usar reescritas para ajeitar as coisas." + +#: Game.Levels.Algorithm.L06is_zero +msgid "" +"See if you can take it from here. Look at the new lemmas and tactic\n" +"available on the right." +msgstr "" +"Veja se você consegue seguir daqui. Olhe os novos lemas e a nova tática\n" +"disponíveis à direita." + +#. §0: `rw [add_left_comm b c]` +#. §1: `b` +#. §2: `c` +#: Game.Levels.Algorithm.L02add_algo1 +msgid "" +"Now use §0 to switch §1 and §2 on the left\n" +"hand side." +msgstr "" +"Agora use §0 para trocar §1 e §2 no lado\n" +"esquerdo." + +#: Game.Levels.Implication +msgid "Implication World" +msgstr "Mundo da Implicação" + +#. §0: `add_succ` +#: Game.Levels.Tutorial.L06add_zero2 +msgid "Let's now learn about Peano's second axiom for addition, §0." +msgstr "Vamos agora aprender o segundo axioma de Peano para a adição, §0." + +#. §0: `h2` +#. §1: `x = 37` +#. §2: `y = 42` +#. §3: `apply` +#. §4: `apply` +#: Game.Levels.Implication.L03apply +msgid "" +"In this level, the hypotheses §0 is an *implication*. It says\n" +"that *if* §1 *then* §2. We can use this\n" +"hypothesis with the §3 tactic. Remember you can click on\n" +"§4 or any other tactic on the right to see a detailed explanation\n" +"of what it does, with examples." +msgstr "" +"Neste nível, a hipótese §0 é uma *implicação*. Ela diz\n" +"que *se* §1 *então* §2. Podemos usar essa\n" +"hipótese com a tática §3. Lembre que você pode clicar em\n" +"§4 ou em qualquer outra tática à direita para ver uma explicação detalhada\n" +"do que ela faz, com exemplos." + +#. §0: `add_comm b c` +#. §1: `b + c = c + b` +#. §2: `a + b + c = a + c + b` +#. §3: `rw [add_comm b c]` +#. §4: `(a + b) + c = (a + c) + b` +#. §5: `b + c` +#. §6: `add_right_comm` +#. §7: `add_assoc` +#. §8: `add_comm` +#. §9: `rw [add_comm b]` +#. §10: `b + ? = ? + b` +#. §11: `rw [add_comm b c]` +#. §12: `b + c = c + b` +#: Game.Levels.Addition.L05add_right_comm +msgid "" +"§0 is a proof that §1. But if your goal\n" +"is §2 then §3 will not\n" +"work! Because the goal means §4 so there\n" +"is no §5 term *directly* in the goal.\n" +"\n" +"Use associativity and commutativity to prove §6.\n" +"You don't need induction. §7 moves brackets around,\n" +"and §8 moves variables around.\n" +"\n" +"Remember that you can do more targetted rewrites by\n" +"adding explicit variables as inputs to theorems. For example §9\n" +"will only do rewrites of the form §10, and §11\n" +"will only do rewrites of the form §12." +msgstr "" +"§0 é uma prova de que §1. Mas se o seu objetivo\n" +"é §2 então §3 não vai\n" +"funcionar! Porque o objetivo significa §4, então não\n" +"existe nenhum termo §5 *diretamente* no objetivo.\n" +"\n" +"Use associatividade e comutatividade para provar §6.\n" +"Você não precisa de indução. §7 move os parênteses,\n" +"e §8 move as variáveis.\n" +"\n" +"Lembre que você pode fazer reescritas mais direcionadas\n" +"adicionando variáveis explícitas como entradas dos teoremas. Por exemplo, §9\n" +"só vai fazer reescritas da forma §10, e §11\n" +"só vai fazer reescritas da forma §12." + +#. §0: `h` +#. §1: `X = Y` +#. §2: `rw [h]` +#. §3: `X` +#. §4: `Y` +#. §5: `rw [← h]` +#. §6: `Y` +#. §7: `X` +#. §8: `\\left ` +#. §9: `\\l` +#. §10: `rw [h1, h2]` +#. §11: `rw [h] at h2` +#. §12: `X` +#. §13: `Y` +#. §14: `h2` +#. §15: `rw [h] at h1 h2 ⊢` +#. §16: `X` +#. §17: `Y` +#. §18: `⊢` +#. §19: `\\|-` +#. §20: `repeat rw [add_zero]` +#. §21: `? + 0` +#. §22: `?` +#. §23: `? + 0` +#. §24: `nth_rewrite 2 [h]` +#. §25: `X` +#. §26: `Y` +#. §27: `h : x = y + y` +#. §28: ``` +#. succ (x + 0) = succ (y + y) +#. ``` +#. §29: `rw [add_zero]` +#. §30: `succ x = succ (y + y)` +#. §31: `rw [h]` +#. §32: `succ (y + y) = succ (y + y)` +#. §33: `rfl` +#. §34: `rw` +#. §35: ``` +#. h1 : x = y + 3 +#. h2 : 2 * y = x +#. ``` +#. §36: `rw [h1] at h2` +#. §37: `h2` +#. §38: `h2 : 2 * y = y + 3` +#. §39: `rw h` +#. §40: `h` +#. §41: `A = B` +#. §42: `h` +#. §43: `rw` +#. §44: `rw [P = Q]` +#. §45: `P = Q` +#. §46: `h : P = Q` +#. §47: `rw [h]` +#. §48: `rw` +#. §49: `h : A = B` +#. §50: `A` +#. §51: `rw [h]` +#. §52: `B` +#. §53: `A` +#. §54: `add_zero` +#. §55: `? + 0 = ?` +#. §56: `add_zero` +#. §57: `?` +#. §58: `rw` +#. §59: `x + 0` +#. §60: `?` +#. §61: `x` +#. §62: `x + 0` +#. §63: `x` +#. §64: `rw [add_zero]` +#. §65: `(0 + 0) + (x + 0) + (0 + 0) + (x + 0)` +#. §66: `0 + (x + 0) + 0 + (x + 0)` +#. §67: `b + c + a = b + (a + c)` +#. §68: `a + c` +#. §69: `c + a` +#. §70: `rw [add_comm]` +#. §71: `rw [add_comm a c]` +#. §72: `a + c` +#. §73: `c + a` +#. §74: `add_comm` +#. §75: `?1 + ?2 = ?2 + ?1` +#. §76: `add_comm a` +#. §77: `a + ? = ? + a` +#. §78: `add_comm a c` +#. §79: `a + c = c + a` +#. §80: `h : X = Y` +#. §81: `rw [h]` +#. §82: `X` +#. §83: `Y` +#. §84: `X` +#. §85: `Y` +#. §86: `nth_rewrite 37 [h]` +#: Game.Levels.Tutorial.L02rw +msgid "" +"## Summary\n" +"\n" +"If §0 is a proof of an equality §1, then §2 will change\n" +"all §3s in the goal to §4s. It's the way to \\\\\"substitute in\\\\\".\n" +"\n" +"## Variants\n" +"\n" +"* §5 (changes §6s to §7s; get the back arrow by typing §8 or §9.)\n" +"\n" +"* §10 (a sequence of rewrites)\n" +"\n" +"* §11 (changes §12s to §13s in hypothesis §14)\n" +"\n" +"* §15 (changes §16s to §17s in two hypotheses and the goal;\n" +"get the §18 symbol with §19.)\n" +"\n" +"* §20 will keep changing §21 to §22\n" +"until there are no more matches for §23.\n" +"\n" +"* §24 will change only the second §25 in the goal to §26.\n" +"\n" +"### Example:\n" +"\n" +"If you have the assumption §27 and your goal is\n" +"§28\n" +"\n" +"then\n" +"\n" +"§29\n" +"\n" +"will change the goal into §30, and then\n" +"\n" +"§31\n" +"\n" +"will change the goal into §32, which\n" +"can be solved with §33.\n" +"\n" +"### Example:\n" +"\n" +"You can use §34 to change a hypothesis as well.\n" +"For example, if you have two hypotheses\n" +"§35\n" +"then §36 will turn §37 into §38.\n" +"\n" +"## Common errors\n" +"\n" +"* You need the square brackets. §39 is never correct.\n" +"\n" +"* If §40 is not a *proof* of an *equality* (a statement of the form §41),\n" +"for example if §42 is a function or an implication,\n" +"then §43 is not the tactic you want to use. For example,\n" +"§44 is never correct: §45 is the theorem *statement*,\n" +"not the proof. If §46 is the proof, then §47 will work.\n" +"\n" +"## Details\n" +"\n" +"The §48 tactic is a way to do \\\\\"substituting in\\\\\". There\n" +"are two distinct situations where you can use this tactic.\n" +"\n" +"1) Basic usage: if §49 is an assumption or\n" +"the proof of a theorem, and if the goal contains one or more §50s, then §51\n" +"will change them all to §52s. The tactic will error\n" +"if there are no §53s in the goal.\n" +"\n" +"2) Advanced usage: Assumptions coming from theorem proofs\n" +"often have missing pieces. For example §54\n" +"is a proof that §55 because §56 really is a function,\n" +"and §57 is the input. In this situation §58 will look through the goal\n" +"for any subterm of the form §59, and the moment it\n" +"finds one it fixes §60 to be §61 then changes all §62s to §63s.\n" +"\n" +"Exercise: think about why §64 changes the term\n" +"§65 to\n" +"§66\n" +"\n" +"If you can't remember the name of the proof of an equality, look it up in\n" +"the list of lemmas on the right.\n" +"\n" +"## Targetted usage\n" +"\n" +"If your goal is §67 and you want to rewrite §68\n" +"to §69, then §70 will not work because Lean finds another\n" +"addition first and swaps those inputs instead. Use §71 to\n" +"guarantee that Lean rewrites §72 to §73. This works because\n" +"§74 is a proof that §75, §76 is a proof\n" +"that §77, and §78 is a proof that §79.\n" +"\n" +"If §80 then §81 will turn all §82s into §83s.\n" +"If you only want to change the 37th occurrence of §84\n" +"to §85 then do §86." +msgstr "" +"## Resumo\n" +"\n" +"Se §0 é uma prova de uma igualdade §1, então §2 vai trocar\n" +"todos os §3 do objetivo por §4. É o jeito de \\\\\"substituir\\\\\".\n" +"\n" +"## Variantes\n" +"\n" +"* §5 (troca §6 por §7; obtenha a seta para trás digitando §8 ou §9.)\n" +"\n" +"* §10 (uma sequência de reescritas)\n" +"\n" +"* §11 (troca §12 por §13 na hipótese §14)\n" +"\n" +"* §15 (troca §16 por §17 em duas hipóteses e no objetivo;\n" +"consiga o símbolo §18 com §19.)\n" +"\n" +"* §20 vai continuar trocando §21 por §22\n" +"até não haver mais ocorrências de §23.\n" +"\n" +"* §24 vai trocar por §26 apenas o segundo §25 do objetivo.\n" +"\n" +"### Exemplo:\n" +"\n" +"Se você tem a hipótese §27 e o seu objetivo é\n" +"§28\n" +"\n" +"então\n" +"\n" +"§29\n" +"\n" +"vai mudar o objetivo para §30, e depois\n" +"\n" +"§31\n" +"\n" +"vai mudar o objetivo para §32, que\n" +"pode ser resolvido com §33.\n" +"\n" +"### Exemplo:\n" +"\n" +"Você também pode usar §34 para mudar uma hipótese.\n" +"Por exemplo, se você tem duas hipóteses\n" +"§35\n" +"então §36 vai transformar §37 em §38.\n" +"\n" +"## Erros comuns\n" +"\n" +"* Você precisa dos colchetes. §39 nunca está correto.\n" +"\n" +"* Se §40 não é uma *prova* de uma *igualdade* (um enunciado da forma §41),\n" +"por exemplo se §42 é uma função ou uma implicação,\n" +"então §43 não é a tática que você quer usar. Por exemplo,\n" +"§44 nunca está correto: §45 é o *enunciado* do teorema,\n" +"não a prova. Se §46 é a prova, então §47 vai funcionar.\n" +"\n" +"## Detalhes\n" +"\n" +"A tática §48 é um jeito de \\\\\"substituir\\\\\". Existem\n" +"duas situações distintas em que você pode usar essa tática.\n" +"\n" +"1) Uso básico: se §49 é uma hipótese ou\n" +"a prova de um teorema, e se o objetivo contém um ou mais §50, então §51\n" +"vai trocar todos eles por §52. A tática dá erro\n" +"se não houver nenhum §53 no objetivo.\n" +"\n" +"2) Uso avançado: hipóteses vindas de provas de teoremas\n" +"muitas vezes têm partes faltando. Por exemplo, §54\n" +"é uma prova de que §55 porque §56 é na verdade uma função,\n" +"e §57 é a entrada. Nessa situação, §58 vai procurar no objetivo\n" +"qualquer subtermo da forma §59, e no momento em que\n" +"encontra um ele fixa §60 como §61 e então troca todos os §62 por §63.\n" +"\n" +"Exercício: pense em por que §64 muda o termo\n" +"§65 para\n" +"§66\n" +"\n" +"Se você não lembrar o nome da prova de uma igualdade, procure\n" +"na lista de lemas à direita.\n" +"\n" +"## Uso direcionado\n" +"\n" +"Se o seu objetivo é §67 e você quer reescrever §68\n" +"como §69, então §70 não vai funcionar porque o Lean encontra outra\n" +"adição primeiro e troca as entradas dela. Use §71 para\n" +"garantir que o Lean reescreva §72 como §73. Isso funciona porque\n" +"§74 é uma prova de que §75, §76 é uma prova\n" +"de que §77, e §78 é uma prova de que §79.\n" +"\n" +"Se §80 então §81 vai transformar todos os §82 em §83.\n" +"Se você só quer mudar a 37ª ocorrência de §84\n" +"para §85, então faça §86." + +#. §0: $a, b,\\ldots h$ +#. §1: $(d + f) + (h + (a + c)) + (g + e + b) = a + b + c + d + e + f + g + h$ +#: Game.Levels.Algorithm.L03add_algo2 Game.Levels.Algorithm.L04add_algo3 +msgid "" +"If §0 are arbitrary natural numbers, we have\n" +"§1." +msgstr "" +"Se §0 são números naturais arbitrários, temos\n" +"§1." + +#. §0: ``` +#. instance instDecidableEq : DecidableEq ℕ +#. | 0, 0 => isTrue <| by +#. show 0 = 0 +#. rfl +#. | succ m, 0 => isFalse <| by +#. show succ m ≠ 0 +#. exact succ_ne_zero m +#. | 0, succ n => isFalse <| by +#. show 0 ≠ succ n +#. exact zero_ne_succ n +#. | succ m, succ n => +#. match instDecidableEq m n with +#. | isTrue (h : m = n) => isTrue <| by +#. show succ m = succ n +#. rw [h] +#. rfl +#. | isFalse (h : m ≠ n) => isFalse <| by +#. show succ m ≠ succ n +#. exact succ_ne_succ m n h +#. ``` +#. §1: `decide` +#: Game.Levels.Algorithm.L08decide +msgid "" +"Implementing the algorithm for equality of naturals, and the proof that it is correct,\n" +"looks like this:\n" +"\n" +"§0\n" +"\n" +"This Lean code is a formally verified algorithm for deciding equality\n" +"between two naturals. I've typed it in already, behind the scenes.\n" +"Because the algorithm is formally verified to be correct, we can\n" +"use it in Lean proofs. You can run the algorithm with the §1 tactic." +msgstr "" +"Implementar o algoritmo para igualdade de naturais, junto com a prova de que ele está correto,\n" +"fica assim:\n" +"\n" +"§0\n" +"\n" +"Esse código Lean é um algoritmo formalmente verificado para decidir a igualdade\n" +"entre dois naturais. Eu já digitei ele, nos bastidores.\n" +"Como o algoritmo é formalmente verificado como correto, podemos\n" +"usá-lo em provas Lean. Você pode rodar o algoritmo com a tática §1." + +#. §0: `P → Q` +#. §1: `intro h` +#. §2: `h : P` +#. §3: `Q` +#. §4: $P \\implies Q$ +#. §5: $P$ +#. §6: $Q$ +#. §7: `x + 1 = y + 1 → x = y` +#. §8: $x+1=y+1 \\implies x=y$ +#. §9: `intro h` +#. §10: $x+1=y+1$ +#. §11: `h` +#. §12: $x=y$ +#: Game.Levels.Implication.L06intro +msgid "" +"## Summary\n" +"\n" +"If the goal is §0, then §1 will introduce §2 as a hypothesis,\n" +"and change the goal to §3. Mathematically, it says that to prove §4,\n" +"we can assume §5 and then prove §6.\n" +"\n" +"### Example:\n" +"\n" +"If your goal is §7 (the way Lean writes §8)\n" +"then §9 will give you a hypothesis §10 named §11, and the goal\n" +"will change to §12." +msgstr "" +"## Resumo\n" +"\n" +"Se o objetivo é §0, então §1 vai introduzir §2 como hipótese,\n" +"e mudar o objetivo para §3. Matematicamente, isso diz que para provar §4,\n" +"podemos supor §5 e então provar §6.\n" +"\n" +"### Exemplo:\n" +"\n" +"Se o seu objetivo é §7 (o jeito que Lean escreve §8)\n" +"então §9 vai te dar uma hipótese §10 chamada §11, e o objetivo\n" +"vai mudar para §12." + +#. §0: `rw [add_zero]` +#. §1: `b + 0` +#. §2: `b` +#: Game.Levels.Tutorial.L05add_zero +msgid "§0 will change §1 into §2." +msgstr "§0 vai transformar §1 para §2." + +#. §0: `apply h2 at h1` +#. §1: `h1` +#. §2: `y = 42` +#: Game.Levels.Implication.L03apply +msgid "Start with §0. This will change §1 to §2." +msgstr "Comece com §0. Isso vai transformar §1 para §2." + +#: Game.Levels.Tutorial.L07add_succ +msgid "[dramatic music]. Now are you ready to face the first boss of the game?" +msgstr "[música dramática]. Você está pronto para encarar o primeiro chefão do jogo?" + +#. §0: $x+y=x\\implies y=0$ +#. §1: `≤` +#: Game.Levels.AdvAddition +msgid "" +"In Advanced Addition World we will prove some basic\n" +"addition facts such as §0. The theorems\n" +"proved in this world will be used to build\n" +"a theory of inequalities in §1 World.\n" +"\n" +"Click on \"Start\" to proceed." +msgstr "" +"No Mundo da Adição Avançada vamos provar alguns fatos básicos\n" +"sobre adição, como §0. Os teoremas\n" +"provados neste mundo serão usados para construir\n" +"uma teoria de desigualdades no Mundo do §1.\n" +"\n" +"Clique em \"Começar\" para continuar." + +#. §0: `tauto` +#. §1: `tauto` +#. §2: `add_zero` +#. §3: `tauto` +#. §4: `a = a` +#. §5: `0 ≠ 1` +#. §6: `0 ≠ 2` +#. §7: `1 ≠ 2` +#. §8: `tauto` +#. §9: `x < 37` +#. §10: `x < 37 → y + z = 42` +#. §11: `y + z = 42` +#. §12: `tauto` +#. §13: `False` +#. §14: `tauto` +#. §15: `True` +#. §16: `tauto` +#. §17: `h1 : a = 37` +#. §18: `h2 : a ≠ 37` +#. §19: `tauto` +#. §20: `False` +#. §21: `False` +#. §22: `h : a ≠ a` +#. §23: `tauto` +#. §24: `tauto` +#. §25: `a = a` +#. §26: `h : 0 = 1` +#. §27: `tauto` +#. §28: `tauto` +#. §29: `0 ≠ 1` +#. §30: `False` +#. §31: `a = 0 → a * b = 0` +#. §32: `a * b ≠ 0 → a ≠ 0` +#. §33: `tauto` +#. §34: `tauto` +#: Game.Levels.AdvMultiplication.L03eq_succ_of_ne_zero +msgid "" +"# Summary\n" +"\n" +"The §0 tactic will solve any goal which can be solved purely by logic (that is, by\n" +"truth tables).\n" +"\n" +"## Details\n" +"\n" +"§1 *does not do magic*! It doesn't know *anything* about addition or multiplication,\n" +"it doesn't even know §2. The only things that §3 knows about numbers\n" +"are firstly that §4 and secondly that §5, §6, §7 and so on.\n" +"What §8's strength is, is *logic*. If you have a hypothesis §9\n" +"and another hypothesis §10 and your goal is §11 then §12 will\n" +"solve this goal, because to solve that goal you don't need to know any facts\n" +"about inequalities or addition, all you need to know is the rules of logic.\n" +"\n" +"## Example\n" +"\n" +"If you have §13 as a hypothesis, then §14 will solve\n" +"the goal. This is because a false hypothesis implies any hypothesis.\n" +"\n" +"## Example\n" +"\n" +"If your goal is §15, then §16 will solve the goal.\n" +"\n" +"## Example\n" +"\n" +"If you have two hypotheses §17 and §18 then §19 will\n" +"solve the goal because it can prove §20 from your hypotheses, and thus\n" +"prove the goal (as §21 implies anything).\n" +"\n" +"## Example\n" +"\n" +"If you have one hypothesis §22 then §23 will solve the goal because\n" +"§24 is smart enough to know that §25 is true, which gives the contradiction we seek.\n" +"\n" +"## Example\n" +"\n" +"If you have a hypothesis §26 then §27 will solve the goal, because\n" +"§28 knows §29 and this is enough to prove §30, which implies any goal.\n" +"\n" +"## Example\n" +"\n" +"If you have a hypothesis of the form §31 and your goal is §32, then\n" +"§33 will solve the goal, because the goal is logically equivalent to the hypothesis.\n" +"If you switch the goal and hypothesis in this example, §34 would solve it too." +msgstr "" +"# Resumo\n" +"\n" +"A tática §0 resolve qualquer objetivo que possa ser resolvido puramente por lógica (ou seja, por\n" +"tabelas-verdade).\n" +"\n" +"## Detalhes\n" +"\n" +"§1 *não faz mágica*! Ela não sabe *nada* sobre adição ou multiplicação,\n" +"nem sequer conhece §2. As únicas coisas que §3 sabe sobre números\n" +"são, primeiro, que §4 e, segundo, que §5, §6, §7 e assim por diante.\n" +"A força de §8 é a *lógica*. Se você tem uma hipótese §9\n" +"e outra hipótese §10 e seu objetivo é §11, então §12 vai\n" +"resolver esse objetivo, porque para resolvê-lo você não precisa saber nenhum fato\n" +"sobre desigualdades ou adição, só precisa conhecer as regras da lógica.\n" +"\n" +"## Exemplo\n" +"\n" +"Se você tem §13 como hipótese, então §14 resolve\n" +"o objetivo. Isso porque uma hipótese falsa implica qualquer hipótese.\n" +"\n" +"## Exemplo\n" +"\n" +"Se o seu objetivo é §15, então §16 resolve o objetivo.\n" +"\n" +"## Exemplo\n" +"\n" +"Se você tem duas hipóteses §17 e §18, então §19 vai\n" +"resolver o objetivo, porque ela consegue provar §20 a partir das suas hipóteses, e assim\n" +"provar o objetivo (já que §21 implica qualquer coisa).\n" +"\n" +"## Exemplo\n" +"\n" +"Se você tem uma hipótese §22, então §23 resolve o objetivo, porque\n" +"§24 é esperta o bastante para saber que §25 é verdade, o que dá a contradição que queremos.\n" +"\n" +"## Exemplo\n" +"\n" +"Se você tem uma hipótese §26, então §27 resolve o objetivo, porque\n" +"§28 sabe que §29 e isso basta para provar §30, que implica qualquer objetivo.\n" +"\n" +"## Exemplo\n" +"\n" +"Se você tem uma hipótese da forma §31 e seu objetivo é §32, então\n" +"§33 resolve o objetivo, porque o objetivo é logicamente equivalente à hipótese.\n" +"Se você trocar objetivo e hipótese neste exemplo, §34 também resolveria." + +#. §0: `rfl` +#: Game.Levels.Tutorial.L03two_eq_ss0 +msgid "Now finish the job with §0." +msgstr "Agora termine o serviço com §0." + +#. §0: `nth_rewrite 2 [← mul_one a] at h` +#: Game.Levels.AdvMultiplication.L10mul_right_eq_self +msgid "Reduce to the previous lemma with §0" +msgstr "Reduza ao lema anterior com §0" + +#. §0: `le_mul_right a b` +#. §1: `a * b ≠ 0 → a ≤ a * b` +#: Game.Levels.AdvMultiplication.L05le_mul_right +msgid "" +"§0 is a proof that §1.\n" +"\n" +"It's one way of saying that a divisor of a positive number\n" +"has to be at most that number." +msgstr "" +"§0 é uma prova de que §1.\n" +"\n" +"É um jeito de dizer que um divisor de um número positivo\n" +"tem que ser no máximo esse número." + +#. §0: $m$ +#. §1: $0 ^{\\operatorname{succ} (m)} = 0$ +#: Game.Levels.Power.L02zero_pow_succ +msgid "For all numbers §0, §1." +msgstr "Para qualquer números §0, §1." + +#. §0: `n` +#: Game.Levels.AdvAddition.L01add_right_cancel +msgid "Start with induction on §0." +msgstr "Comece com indução em §0." + +#: Game.Levels.LessOrEqual.L08le_total +msgid "x ≤ y or y ≤ x" +msgstr "x ≤ y ou y ≤ x" + +#. §0: `use` +#. §1: `c` +#. §2: `x = 0 + c` +#: Game.Levels.LessOrEqual.L02zero_le +msgid "To solve this level, you need to §0 a number §1 such that §2." +msgstr "Para resolver este nível, você precisa usar §0 com um número §1 tal que §2." + +#. §0: `le_mul_right` +#. §1: `x * y ≠ 0` +#. §2: `have h2 : x * y ≠ 0` +#. §3: `≠` +#. §4: `\\ne` +#. §5: `le_mul_right` +#: Game.Levels.AdvMultiplication.L06mul_right_eq_one +msgid "" +"We want to use §0, but we need a hypothesis §1\n" +"which we don't have. Yet. Execute §2 (you can type §3 with §4).\n" +"You'll be asked to\n" +"prove it, and then you'll have a new hypothesis which you can apply\n" +"§5 to." +msgstr "" +"Queremos usar §0, mas precisamos de uma hipótese §1\n" +"que não temos. Ainda. Execute §2 (você pode digitar §3 com §4).\n" +"Você terá que\n" +"prová-la, e então terá uma nova hipótese na qual poderá aplicar\n" +"§5." + +#. §0: $x=37$ +#. §1: $x=37\\implies y=42$ +#. §2: $y=42$ +#: Game.Levels.Implication.L03apply +msgid "If §0 and we know that §1 then we can deduce §2." +msgstr "Se §0 e sabemos que §1 então podemos deduzir §2." + +#. §0: `rfl` +#. §1: `X = X` +#. §2: `rfl` +#. §3: `A = B` +#. §4: `A` +#. §5: `B` +#. §6: `rfl` +#. §7: ``` +#. x + 37 = x + 37 +#. ``` +#. §8: `rfl` +#. §9: `0 + x = x` +#. §10: `rfl` +#. §11: $0+x$ +#. §12: $x$ +#. §13: `0 + x` +#. §14: `0 + x` +#. §15: `rfl` +#. §16: `rfl` +#. §17: `mathlib` +#. §18: `zero_add` +#. §19: `add_zero` +#: Game.Levels.Tutorial.L01rfl +msgid "" +"## Summary\n" +"\n" +"§0 proves goals of the form §1.\n" +"\n" +"In other words, the §2 tactic will close any goal of the\n" +"form §3 if §4 and §5 are *identical*.\n" +"\n" +"§6 is short for \\\\\"reflexivity (of equality)\\\\\".\n" +"\n" +"## Example:\n" +"\n" +"If the goal looks like this:\n" +"\n" +"§7\n" +"\n" +"then §8 will close it. But if it looks like §9 then §10 won't work, because even\n" +"though §11 and §12 are always equal as *numbers*, they are not equal as *terms*.\n" +"The only term which is identical to §13 is §14.\n" +"\n" +"## Details\n" +"\n" +"§15 is short for \\\\\"reflexivity of equality\\\\\".\n" +"\n" +"## Game Implementation\n" +"\n" +"*Note that our §16 is weaker than the version used in core Lean and §17,\n" +"for pedagogical purposes; mathematicians do not distinguish between propositional\n" +"and definitional equality because they think about definitions in a different way\n" +"to type theorists (§18 and §19 are both \\\\\"facts\\\\\" as far\n" +"as mathematicians are concerned, and who cares what the definition of addition is).*" +msgstr "" +"## Resumo\n" +"\n" +"§0 prova objetivos da forma §1.\n" +"\n" +"Em outras palavras, a tática §2 fecha qualquer objetivo da\n" +"forma §3 se §4 e §5 forem *idênticos*.\n" +"\n" +"§6 é abreviação de \\\"reflexividade (da igualdade)\\\".\n" +"\n" +"## Exemplo:\n" +"\n" +"Se o objetivo for assim:\n" +"\n" +"§7\n" +"\n" +"então §8 vai fechá-lo. Mas se for §9 então §10 não vai funcionar, pois mesmo\n" +"que §11 e §12 sejam sempre iguais como *números*, eles não são iguais como *termos*.\n" +"O único termo idêntico a §13 é §14.\n" +"\n" +"## Detalhes\n" +"\n" +"§15 é abreviação de \\\"reflexividade da igualdade\\\".\n" +"\n" +"## Implementação no jogo\n" +"\n" +"*Note que nosso §16 é mais fraco que a versão usada no núcleo do Lean e na §17,\n" +"por motivos pedagógicos; matemáticos não distinguem entre igualdade proposicional\n" +"e definicional porque pensam sobre definições de um jeito diferente dos\n" +"teóricos de tipos (§18 e §19 são ambos \\\"fatos\\\" no que diz respeito\n" +"aos matemáticos, e quem se importa com qual é a definição de adição).*" + +#. §0: `b = 0` +#. §1: `a * b = 0` +#. §2: `X ≠ 0` +#. §3: `X = 0 → False` +#. §4: `Show more help!` +#: Game.Levels.AdvMultiplication.L02mul_left_ne_zero +msgid "" +"We want to reduce this to a hypothesis §0 and a goal §1,\n" +"which is logically equivalent but much easier to prove. Remember that §2\n" +"is notation for §3. Click on §4 if you need hints." +msgstr "" +"Queremos reduzir isso a uma hipótese §0 e um objetivo §1,\n" +"que é logicamente equivalente mas muito mais fácil de provar. Lembre que §2\n" +"é notação para §3. Clique em `Mostrar mais ajuda!` se precisar de dicas." + +#. §0: `repeat rw [add_zero]` +#: Game.Levels.Tutorial.L05add_zero +msgid "" +"Those of you interested in speedrunning the game may want to know\n" +"that §0 will do both rewrites at once." +msgstr "" +"Quem tiver interesse em fazer speedrun do jogo talvez queira saber\n" +"que §0 faz as duas reescritas de uma vez só." + +#. §0: $0$ +#. §1: $0$ +#. §2: `37 + d = q` +#. §3: `37 + succ d` +#. §4: `succ d` +#. §5: `d` +#. §6: `37 + succ d` +#. §7: `succ q` +#. §8: `q` +#. §9: `x + succ d` +#. §10: `succ (x + d)` +#. §11: `add_succ x d : x + succ d = succ (x + d)` +#. §12: `... + succ ...` +#. §13: `rw [add_succ]` +#. §14: `succ n = n + 1` +#. §15: `+ succ` +#. §16: `rw [add_succ]` +#. §17: `+` +#. §18: `012` +#: Game.Levels.Tutorial.L07add_succ +msgid "" +"Every number in Lean is either §0 or a successor. We know how to add §1,\n" +"but we need to figure out how to add successors. Let's say we already know\n" +"that §2. What should the answer to §3 be? Well,\n" +"§4 is one bigger than §5, so §6 should be §7,\n" +"the number one bigger than §8. More generally §9 should\n" +"be §10. Let's add this as a lemma.\n" +"\n" +"* §11\n" +"\n" +"If you ever see §12 in your goal, §13 is\n" +"normally a good idea.\n" +"\n" +"Let's now prove that §14. Figure out how to get §15 into\n" +"the picture, and then §16. Switch between the §17 (addition) and\n" +"§18 (numerals) tabs under \"Theorems\" on the right to\n" +"see which proofs you can rewrite." +msgstr "" +"Todo número em Lean é §0 ou um sucessor. Sabemos como somar §1,\n" +"mas precisamos descobrir como somar sucessores. Digamos que já sabemos\n" +"que §2. Qual deveria ser a resposta de §3? Bem,\n" +"§4 é um a mais que §5, então §6 deveria ser §7,\n" +"o número um a mais que §8. De forma geral, §9 deveria\n" +"ser §10. Vamos adicionar isso como um lema.\n" +"\n" +"* §11\n" +"\n" +"Sempre que você vir §12 no seu objetivo, §13 costuma\n" +"ser uma boa ideia.\n" +"\n" +"Agora vamos provar que §14. Descubra como colocar §15 em\n" +"cena, e então faça §16. Alterne entre as abas §17 (adição) e\n" +"§18 (numerais) em \"Theorems\" à direita para\n" +"ver quais provas você pode reescrever." + +#. §0: `trivial` +#. §1: `True` +#: Game.Levels.Algorithm.L06is_zero +msgid "" +"# Summary\n" +"\n" +"§0 will solve the goal §1." +msgstr "" +"# Resumo\n" +"\n" +"§0 resolve o objetivo §1." + +#. §0: $0^0=1$ +#. §1: $0^n=0$ +#. §2: $n>0$ +#. §3: $n$ +#: Game.Levels.Power.L02zero_pow_succ +msgid "" +"Although §0 in this game, §1 if §2, i.e., if\n" +"§3 is a successor." +msgstr "" +"Embora §0 neste jogo, §1 se §2, ou seja, se\n" +"§3 for um sucessor." + +#. §0: `b = 0` +#. §1: `b ≠ 0` +#. §2: `cases b with d` +#: Game.Levels.AdvAddition.L05add_right_eq_zero +msgid "" +"Here we want to deal with the cases §0 and §1 separately,\n" +"so start with §2." +msgstr "" +"Aqui queremos tratar os casos §0 e §1 separadamente,\n" +"então comece com §2." + +#. §0: `hd` +#. §1: `c` +#. §2: `a * d = a * c → d = c` +#. §3: `apply` +#. §4: `at` +#. §5: `a * d = a * ?` +#: Game.Levels.AdvMultiplication.L09mul_left_cancel +msgid "" +"The inductive hypothesis §0 is \"For all natural numbers §1, §2\".\n" +"You can §3 it §4 any hypothesis of the form §5." +msgstr "" +"A hipótese indutiva §0 é \"Para todo número natural §1, §2\".\n" +"Você pode fazer §3 dela §4 qualquer hipótese da forma §5." + +#: Game.Levels.Multiplication.L07mul_add +msgid "" +"You can do induction on any of the three variables. Some choices\n" +"are harder to push through than others. Can you do the inductive step in\n" +"5 rewrites only?" +msgstr "" +"Você pode fazer indução em qualquer uma das três variáveis. Algumas escolhas\n" +"são mais difíceis de levar até o fim do que outras. Você consegue fazer o passo indutivo em\n" +"apenas 5 reescritas?" + +#. §0: `0 + «{d}»` +#. §1: `rw [«{hd}»]` +#: Game.Levels.Addition.L01zero_add +msgid "" +"At this point you see the term §0, so you can use the\n" +"induction hypothesis with §1." +msgstr "" +"Neste ponto você vê o termo §0, então pode usar a\n" +"hipótese de indução com §1." + +#. §0: `0 ^ 0` +#. §1: `0 ^ 0 = 1` +#: Game.Levels.Power.L01zero_pow_zero +msgid "" +"Mathematicians sometimes debate what §0 is;\n" +"the answer depends, of course, on your definitions. In this\n" +"game, §1. See if you can prove it.\n" +"\n" +"Check out the *Pow* tab in your list of theorems\n" +"to see the new proofs which are available." +msgstr "" +"Os matemáticos às vezes discutem quanto vale §0;\n" +"a resposta depende, é claro, das suas definições. Neste\n" +"jogo, §1. Veja se você consegue provar isso.\n" +"\n" +"Dê uma olhada na aba *Pow* na sua lista de teoremas\n" +"para ver as novas provas disponíveis." + +#. §0: `1` +#. §1: `succ 0` +#. §2: `h` +#: Game.Levels.Implication.L09zero_ne_succ +msgid "Now change §0 to §1 in §2." +msgstr "Agora troque §0 por §1 em §2." + +#. §0: `apply t at h` +#. §1: `apply t` +#. §2: `apply` +#: Game.Levels.Implication.L05succ_inj2 +msgid "" +"Many people find §0 easy, but some find §1 confusing.\n" +"If you find it confusing, then just argue forwards.\n" +"\n" +"You can read more about the §2 tactic in its documentation, which you can view by\n" +"clicking on the tactic in the list on the right." +msgstr "" +"Muita gente acha §0 fácil, mas algumas pessoas acham §1 confuso.\n" +"Se você achar confuso, então argumente para frente.\n" +"\n" +"Você pode ler mais sobre a tática §2 na documentação dela, que você pode ver\n" +"clicando na tática na lista à direita." + +#: Game.Levels.Algorithm.L03add_algo2 +msgid "Let's now make our own tactic to do this." +msgstr "Vamos agora criar nossa própria tática para fazer isso." + +#: Game.Levels.AdvAddition.L06add_left_eq_zero +msgid "add_left_eq_zero" +msgstr "add_left_eq_zero" + +#. §0: `rw [add_succ]` +#: Game.Levels.Tutorial.L07add_succ Game.Levels.Tutorial.L08twoaddtwo +msgid "Now you can §0" +msgstr "Agora você pode fazer §0" + +#. §0: `←` +#. §1: `rw` +#. §2: `rw` +#. §3: `←` +#. §4: `\\l` +#: Game.Levels.Implication.L04succ_inj +msgid "" +"You can put a §0 in front of any theorem provided to §1 to rewrite\n" +"the other way around. Look at the docs for §2 for an explanation. Type §3 with §4." +msgstr "" +"Você pode colocar um §0 na frente de qualquer teorema passado para §1 para reescrever\n" +"no sentido contrário. Veja a documentação de §2 para uma explicação. Digite §3 com §4." + +#. §0: `exact h` +#: Game.Levels.Implication.L05succ_inj2 +msgid "You can now finish with §0." +msgstr "Agora você pode terminar com §0." + +#: Game +msgid "Natural Number Game" +msgstr "Jogo dos Números Naturais" + +#. §0: ``` +#. rw [add_comm] +#. exact add_right_eq_zero b a +#. ``` +#. §1: `≤` +#: Game.Levels.AdvAddition.L06add_left_eq_zero +msgid "" +"How about this for a proof:\n" +"\n" +"§0\n" +"\n" +"That's the end of Advanced Addition World! You'll need these theorems\n" +"for the next world, §1 World. Click on \"Leave World\" to access it." +msgstr "" +"Que tal esta prova:\n" +"\n" +"§0\n" +"\n" +"Esse é o fim do Mundo da Adição Avançada! Você vai precisar destes teoremas\n" +"no próximo mundo, o Mundo do §1. Clique em \"Leave World\" para acessá-lo." + +#. §0: `n` +#. §1: `cases n with d` +#. §2: `n = 0` +#. §3: `n = succ d` +#. §4: `h` +#. §5: `cases h with...` +#. §6: `n : ℕ` +#. §7: `cases n with d` +#. §8: `n` +#. §9: `n` +#. §10: `succ d` +#. §11: `0` +#. §12: `h : P ∨ Q` +#. §13: `cases h with hp hq` +#. §14: `hp : P` +#. §15: `hq : Q` +#. §16: `h : False` +#. §17: `cases h` +#. §18: `False` +#. §19: `h : a ≤ b` +#. §20: `cases h with c hc` +#. §21: `c` +#. §22: `hc : b = a + c` +#. §23: `a ≤ b` +#. §24: `∃ c, b = a + c` +#: Game.Levels.AdvAddition.L05add_right_eq_zero +msgid "" +"## Summary\n" +"\n" +"If §0 is a number, then §1 will break the goal into two goals,\n" +"one with §2 and the other with §3.\n" +"\n" +"If §4 is a proof (for example a hypothesis), then §5 will break the\n" +"proof up into the pieces used to prove it.\n" +"\n" +"## Example\n" +"\n" +"If §6 is a number, then §7 will break the goal into two goals,\n" +"one with §8 replaced by 0 and the other with §9 replaced by §10. This\n" +"corresponds to the mathematical idea that every natural number is either §11\n" +"or a successor.\n" +"\n" +"## Example\n" +"\n" +"If §12 is a hypothesis, then §13 will turn one goal\n" +"into two goals, one with a hypothesis §14 and the other with a\n" +"hypothesis §15.\n" +"\n" +"## Example\n" +"\n" +"If §16 is a hypothesis, then §17 will turn one goal into no goals,\n" +"because there are no ways to make a proof of §18! And if you have no goals left,\n" +"you have finished the level.\n" +"\n" +"## Example\n" +"\n" +"If §19 is a hypothesis, then §20 will create a new number §21\n" +"and a proof §22. This is because the *definition* of §23 is\n" +"§24." +msgstr "" +"## Resumo\n" +"\n" +"Se §0 é um número, então §1 vai quebrar o objetivo em dois objetivos,\n" +"um com §2 e o outro com §3.\n" +"\n" +"Se §4 é uma prova (por exemplo, uma hipótese), então §5 vai quebrar a\n" +"prova nos pedaços usados para prová-la.\n" +"\n" +"## Exemplo\n" +"\n" +"Se §6 é um número, então §7 vai quebrar o objetivo em dois objetivos,\n" +"um com §8 substituído por 0 e o outro com §9 substituído por §10. Isso\n" +"corresponde à ideia matemática de que todo número natural é §11\n" +"ou um sucessor.\n" +"\n" +"## Exemplo\n" +"\n" +"Se §12 é uma hipótese, então §13 vai transformar um objetivo\n" +"em dois objetivos, um com uma hipótese §14 e o outro com uma\n" +"hipótese §15.\n" +"\n" +"## Exemplo\n" +"\n" +"Se §16 é uma hipótese, então §17 vai transformar um objetivo em nenhum objetivo,\n" +"porque não há jeito nenhum de construir uma prova de §18! E se você não tem mais objetivos,\n" +"você terminou o nível.\n" +"\n" +"## Exemplo\n" +"\n" +"Se §19 é uma hipótese, então §20 vai criar um novo número §21\n" +"e uma prova §22. Isso porque a *definição* de §23 é\n" +"§24." + +#. §0: `«{ha}»` +#. §1: `«{y}» = «{x}» + «{a}»` +#. §2: `hxy` +#. §3: `«{hyz}»` +#. §4: `cases «{hyz}» with b hb` +#: Game.Levels.LessOrEqual.L04le_trans +msgid "" +"Now §0 is a proof that §1, and §2 has vanished. Similarly, you can destruct\n" +"§3 into its parts with §4." +msgstr "" +"Agora §0 é uma prova de que §1, e §2 sumiu. Do mesmo jeito, você pode destrinchar\n" +"§3 em suas partes com §4." + +#: Game.Levels.Implication.L04succ_inj +msgid "succ_inj : the successor function is injective" +msgstr "succ_inj : a função sucessor é injetiva" + +#. §0: `b + 0` +#. §1: `c + 0` +#. §2: `rw [add_zero]` +#. §3: `b + 0` +#. §4: `c + 0` +#. §5: `add_zero` +#: Game.Levels.Tutorial.L06add_zero2 +msgid "" +"## Precision rewriting\n" +"\n" +"In the last level, there was §0 and §1,\n" +"and §2 changed the first one it saw,\n" +"which was §3. Let's learn how to tell Lean\n" +"to change §4 first by giving §5 an\n" +"explicit input." +msgstr "" +"## Reescrita com precisão\n" +"\n" +"No nível anterior, havia §0 e §1,\n" +"e §2 mudou o primeiro que encontrou,\n" +"que era §3. Vamos aprender a dizer ao Lean\n" +"para mudar §4 primeiro, dando a §5 uma\n" +"entrada explícita." + +#. §0: `a ≤ b` +#. §1: `∃ c, b = a + c` +#. §2: `a ≤ b` +#. §3: `use` +#. §4: `h : a ≤ b` +#. §5: `cases h with c hc` +#: Game.Levels.LessOrEqual.L01le_refl +msgid "" +"§0 is *notation* for §1.\n" +"\n" +"Because this game doesn't have negative numbers, this definition\n" +"is mathematically valid.\n" +"\n" +"This means that if you have a goal of the form §2 you can\n" +"make progress with the §3 tactic, and if you have a hypothesis\n" +"§4, you can make progress with §5." +msgstr "" +"§0 é *notação* para §1.\n" +"\n" +"Como este jogo não tem números negativos, essa definição\n" +"é matematicamente válida.\n" +"\n" +"Isso significa que, se você tem um objetivo da forma §2, você pode\n" +"avançar com a tática §3, e se você tem uma hipótese\n" +"§4, você pode avançar com §5." + +#. §0: `exact h` +#: Game.Levels.Implication.L06intro +msgid "Now §0 finishes the job." +msgstr "Agora §0 termina o serviço." + +#. §0: `«{x}» ≤ «{x}»` +#. §1: `«{x}» = «{x}» + 0` +#. §2: `use 0` +#: Game.Levels.LessOrEqual.L01le_refl +msgid "" +"The reason §0 is because §1.\n" +"So you should start this proof with §2." +msgstr "" +"A razão de §0 é que §1.\n" +"Então você deve começar esta prova com §2." + +#. §0: $x \\leq y$ +#. §1: $y \\leq z$ +#. §2: $x \\leq z$ +#: Game.Levels.LessOrEqual.L04le_trans Game.Levels.LessOrEqual.L06le_antisymm +msgid "If §0 and §1, then §2." +msgstr "Se §0 e §1, então §2." + +#. §0: ``` +#. apply mul_left_ne_zero at h +#. apply one_le_of_ne_zero at h +#. apply mul_le_mul_right 1 b a at h +#. rw [one_mul, mul_comm] at h +#. exact h +#. ``` +#: Game.Levels.AdvMultiplication.L05le_mul_right +msgid "" +"Here's what I was thinking of:\n" +"§0" +msgstr "" +"Eu pensei assim:\n" +"§0" + +#. §0: `nth_rewrite 2 [two_eq_succ_one]` +#. §1: `rw [two_eq_succ_one]` +#: Game.Levels.Tutorial.L08twoaddtwo +msgid "§0 is I think quicker than §1." +msgstr "§0 é, eu acho, mais rápido do que §1." + +#: GameServer.RpcHandlers +msgid "intermediate goal solved! 🎉" +msgstr "objetivo intermediário resolvido! 🎉" + +#. §0: $a, b$ +#. §1: $c$ +#. §2: $ (a + b) + c = a + (b + c). $ +#: Game.Levels.Addition.L04add_assoc +msgid "" +"On the set of natural numbers, addition is associative.\n" +"In other words, if §0 and §1 are arbitrary natural numbers, we have\n" +"§2" +msgstr "" +"No conjunto dos números naturais, a adição é associativa.\n" +"Em outras palavras, se §0 e §1 são números naturais arbitrários, temos\n" +"§2" + +#. §0: `use` +#: Game.Levels.LessOrEqual.L04le_trans +msgid "Now you need to figure out which number to §0. See if you can take it from here." +msgstr "Agora você precisa descobrir qual número usar no §0. Veja se você consegue seguir daqui." + +#. §0: `t : P → Q` +#. §1: $P \\implies Q$ +#. §2: `h : P` +#. §3: `P` +#. §4: `apply t at h` +#. §5: `h` +#. §6: `Q` +#. §7: `P` +#. §8: `t` +#. §9: `Q` +#. §10: `Q` +#. §11: `apply t` +#. §12: `P` +#. §13: `Q` +#. §14: `t` +#. §15: `P` +#. §16: `P` +#. §17: `succ_inj x y` +#. §18: `succ x = succ y → x = y` +#. §19: `h : succ (a + 37) = succ (b + 42)` +#. §20: `apply succ_inj at h` +#. §21: `h` +#. §22: `a + 37 = b + 42` +#. §23: `apply succ_inj (a + 37) (b + 42) at h` +#. §24: `succ_inj` +#. §25: `a * b = 7` +#. §26: `apply succ_inj` +#. §27: `succ (a * b) = succ 7` +#: Game.Levels.Implication.L03apply +msgid "" +"## Summary\n" +"\n" +"If §0 is a proof that §1, and §2 is a proof of §3,\n" +"then §4 will change §5 to a proof of §6. The idea is that if\n" +"you know §7 is true, then you can deduce from §8 that §9 is true.\n" +"\n" +"If the *goal* is §10, then §11 will \\\\\"argue backwards\\\\\" and change the\n" +"goal to §12. The idea here is that if you want to prove §13, then by §14\n" +"it suffices to prove §15, so you can reduce the goal to proving §16.\n" +"\n" +"### Example:\n" +"\n" +"§17 is a proof that §18.\n" +"\n" +"So if you have a hypothesis §19\n" +"then §20 will change §21 to §22.\n" +"You could write §23\n" +"but Lean is smart enough to figure out the inputs to §24.\n" +"\n" +"### Example\n" +"\n" +"If the goal is §25, then §26 will turn the\n" +"goal into §27." +msgstr "" +"## Resumo\n" +"\n" +"Se §0 é uma prova de que §1, e §2 é uma prova de §3,\n" +"então §4 vai transformar §5 numa prova de §6. A ideia é que, se\n" +"você sabe que §7 é verdadeiro, então pode deduzir de §8 que §9 é verdadeiro.\n" +"\n" +"Se o *objetivo* for §10, então §11 vai \\\\\"argumentar de trás para frente\\\\\" e mudar o\n" +"objetivo para §12. A ideia aqui é que, se você quer provar §13, então por §14\n" +"basta provar §15, de modo que você pode reduzir o objetivo a provar §16.\n" +"\n" +"### Exemplo:\n" +"\n" +"§17 é uma prova de que §18.\n" +"\n" +"Então, se você tem uma hipótese §19,\n" +"§20 vai mudar §21 para §22.\n" +"Você poderia escrever §23,\n" +"mas Lean é esperto o bastante para descobrir sozinho as entradas de §24.\n" +"\n" +"### Exemplo\n" +"\n" +"Se o objetivo é §25, então §26 vai transformar o\n" +"objetivo em §27." + +#. §0: `cases «{h2}» with e he` +#: Game.Levels.LessOrEqual.L08le_total +msgid "Now §0." +msgstr "Agora faça §0." + +#. §0: `add_mul` +#: Game.Levels.Multiplication.L08add_mul +msgid "" +"§0 is just as fiddly to prove by induction; but there's a trick\n" +"which avoids it. Can you spot it?" +msgstr "" +"§0 é igualmente chato de provar por indução; mas existe um truque\n" +"que evita isso. Consegue achá-lo?" + +#. §0: `repeat rw [← succ_eq_add_one] at h` +#. §1: `h` +#. §2: `succ x = succ y` +#: Game.Levels.Implication.L07intro2 +msgid "" +"Now §0 is the quickest way to\n" +"change §1 to §2." +msgstr "" +"Agora §0 é o jeito mais rápido de\n" +"transformar §1 em §2." + +#. §0: ``` +#. use 1 +#. exact succ_eq_add_one x +#. ``` +#. §1: `succ_eq_add_one x` +#. §2: `succ x = x + 1` +#: Game.Levels.LessOrEqual.L03le_succ_self +msgid "" +"Here's a two-liner:\n" +"§0\n" +"\n" +"This works because §1 is a proof of §2." +msgstr "" +"Aqui vai uma solução de duas linhas:\n" +"§0\n" +"\n" +"Isso funciona porque §1 é uma prova de §2." + +#. §0: `intro h` +#. §1: `X ≠ Y` +#. §2: `X = Y → False` +#: Game.Levels.Algorithm.L06is_zero +msgid "" +"Start with §0 (remembering that §1 is just notation\n" +"for §2)." +msgstr "" +"Comece com §0 (lembrando que §1 é apenas notação\n" +"para §2)." + +#. §0: `n` +#. §1: `induction n with d hd` +#: Game.Levels.Addition.L01zero_add +msgid "" +"You can start a proof by induction on §0 by typing:\n" +"§1." +msgstr "" +"Você pode começar uma prova por indução em §0 digitando:\n" +"§1." + +#. §0: `Pow a b` +#. §1: `a ^ b` +#. §2: `pow_zero a : a ^ 0 = 1` +#. §3: `pow_succ a b : a ^ succ b = a ^ b * a` +#. §4: `0 ^ 0 = 1` +#: Game.Levels.Power.L01zero_pow_zero +msgid "" +"§0, with notation §1, is the usual\n" +" exponentiation of natural numbers. Internally it is\n" +" defined via two axioms:\n" +"\n" +" * §2\n" +"\n" +" * §3\n" +"\n" +"Note in particular that §4." +msgstr "" +"§0, com notação §1, é a exponenciação\n" +" usual de números naturais. Internamente ela é\n" +" definida por dois axiomas:\n" +"\n" +" * §2\n" +"\n" +" * §3\n" +"\n" +"Note em particular que §4." + +#. §0: `≤` +#. §1: `a` +#. §2: `b` +#. §3: `a ≤ b` +#. §4: `b ≤ a` +#. §5: `or` +#. §6: `∨` +#. §7: `\\or` +#. §8: `left` +#. §9: `right` +#. §10: `h` +#. §11: `cases h with h1 h2` +#: Game.Levels.LessOrEqual.L07or_symm +msgid "" +"Totality of §0 is the boss level of this world, and it's coming up next. It says that\n" +"if §1 and §2 are naturals then either §3 or §4.\n" +"But we haven't talked about §5 at all. Here's a run-through.\n" +"\n" +"1) The notation for \"or\" is §6. You won't need to type it, but you can\n" +"type it with §7.\n" +"\n" +"2) If you have an \"or\" statement in the *goal*, then two tactics make\n" +"progress: §8 and §9. But don't choose a direction unless your\n" +"hypotheses guarantee that it's the correct one.\n" +"\n" +"3) If you have an \"or\" statement as a *hypothesis* §10, then\n" +"§11 will create two goals, one where you went left,\n" +"and the other where you went right." +msgstr "" +"A totalidade de §0 é o chefão deste mundo, e vem a seguir. Ela diz que,\n" +"se §1 e §2 são naturais, então §3 ou §4.\n" +"Mas não falamos nada sobre §5 até agora. Aqui vai uma visão geral.\n" +"\n" +"1) A notação para \"ou\" é §6. Você não vai precisar digitá-la, mas pode\n" +"digitá-la com §7.\n" +"\n" +"2) Se você tem uma afirmação com \"ou\" no *objetivo*, então duas táticas fazem\n" +"progresso: §8 e §9. Mas não escolha uma direção a menos que suas\n" +"hipóteses garantam que ela é a correta.\n" +"\n" +"3) Se você tem uma afirmação com \"ou\" como *hipótese* §10, então\n" +"§11 vai criar dois objetivos, um em que você foi para a esquerda,\n" +"e outro em que você foi para a direita." + +#. §0: `one_eq_succ_zero` +#. §1: `1 = succ 0` +#: Game.Levels.Tutorial.L03two_eq_ss0 +msgid "§0 is a proof of §1.\"" +msgstr "§0 é uma prova de §1.\"" + +#: Game.Levels.Addition.L01zero_add +msgid "zero_add" +msgstr "zero_add" + +#. §0: `induction b with d hd generalizing c` +#: Game.Levels.AdvMultiplication.L09mul_left_cancel +msgid "The way to start this proof is §0." +msgstr "O jeito de começar essa prova é §0." + +#. §0: `0 ^ 0 = 1` +#. §1: `n` +#. §2: `0 ^ n = 0` +#: Game.Levels.Power.L02zero_pow_succ +msgid "" +"We've just seen that §0, but if §1\n" +"is a successor, then §2. We prove that here." +msgstr "" +"Acabamos de ver que §0, mas se §1\n" +"é um sucessor, então §2. Vamos provar isso aqui." + +#. §0: `zero_mul x` +#. §1: `0 * x = 0` +#. §2: `zero_mul` +#. §3: `simp` +#: Game.Levels.Multiplication.L02zero_mul +msgid "" +"§0 is the proof that §1.\n" +"\n" +"Note: §2 is a §3 lemma." +msgstr "" +"§0 é a prova de que §1.\n" +"\n" +"Observação: §2 é um lema §3." + +#. §0: $\\leq$ +#. §1: $x \\leq y$ +#. §2: $y \\leq x$ +#. §3: $x = y$ +#: Game.Levels.LessOrEqual.L06le_antisymm +msgid "" +"This level asks you to prove *antisymmetry* of §0.\n" +"In other words, if §1 and §2 then §3.\n" +"It's the trickiest one so far. Good luck!" +msgstr "" +"Este nível pede que você prove a *antissimetria* de §0.\n" +"Em outras palavras, se §1 e §2 então §3.\n" +"É o mais complicado até agora. Boa sorte!" + +#. §0: `contrapose!` +#: Game.Levels.AdvMultiplication.L02mul_left_ne_zero +msgid "" +"If you have completed Algorithm World then you can use the §0 tactic\n" +"here. If not then I'll talk you through a manual approach." +msgstr "" +"Se você completou o Mundo dos Algoritmos, então pode usar a tática §0\n" +"aqui. Se não, vou te guiar por uma abordagem manual." + +#. §0: `zero_ne_succ n` +#. §1: `0 ≠ succ n` +#. §2: `a ≠ b` +#. §3: `a = b → False` +#. §4: `zero_ne_succ n` +#. §5: `0 = succ n → False` +#. §6: `False` +#. §7: `apply zero_ne_succ at h` +#. §8: `h` +#. §9: `0 = succ n` +#: Game.Levels.Implication.L09zero_ne_succ +msgid "" +"§0 is the proof that §1.\n" +"\n" +"In Lean, §2 is *defined to mean* §3. Hence\n" +"§4 is really a proof of §5.\n" +"Here §6 is a generic false statement. This means that\n" +"you can §7 if §8 is a proof of §9." +msgstr "" +"§0 é a prova de que §1.\n" +"\n" +"Em Lean, §2 é *definido como* §3. Portanto\n" +"§4 é na verdade uma prova de §5.\n" +"Aqui §6 é uma afirmação falsa genérica. Isso significa que\n" +"você pode fazer §7 se §8 é uma prova de §9." + +#: Game.Levels.Multiplication.L01mul_one +msgid "mul_one" +msgstr "mul_one" + +#. §0: `add_left_cancel a b n` +#. §1: $n+a=n+b\\implies a=b$ +#. §2: `n` +#. §3: `add_right_cancel` +#: Game.Levels.AdvAddition.L02add_left_cancel +msgid "" +"§0 is the theorem that §1.\n" +"You can prove it by induction on §2 or you can deduce it from §3." +msgstr "" +"§0 é o teorema de que §1.\n" +"Você pode prová-lo por indução em §2 ou pode o deduzir usando §3." + +#. §0: `rw [«{h}»] at «{h2}»` +#. §1: `apply le_one at «{h2}»` +#: Game.Levels.AdvMultiplication.L06mul_right_eq_one +msgid "Now §0 so you can §1." +msgstr "Agora faça §0, para você poder fazer §1." + +#. §0: $x \\leq 2$ +#. §1: $x = 0$ +#. §2: $1$ +#. §3: $2$ +#: Game.Levels.LessOrEqual.L11le_two +msgid "If §0 then §1 or §2 or §3." +msgstr "Se §0 então §1 ou §2 ou §3." + +#. §0: `two_eq_succ_one` +#. §1: `2 = succ 1` +#: Game.Levels.Tutorial.L03two_eq_ss0 Game.Levels.Addition.L03add_comm +#: Game.Levels.Implication.L09zero_ne_succ Game.Levels.Algorithm.L05pred Game.Levels.Algorithm.L06is_zero +#: Game.Levels.LessOrEqual.L05le_zero +msgid "§0 is a proof of §1." +msgstr "§0 é uma prova de §1." + +#. §0: $a$ +#. §1: $b$ +#. §2: $c$ +#. §3: $n$ +#. §4: $$(a+1)^{n+3}+(b+1)^{n+3}\\not=(c+1)^{n+3}.$$ +#: Game.Levels.Power.L10FLT +msgid "" +"For all naturals §0 §1 §2 and §3, we have\n" +"§4" +msgstr "" +"Para quaisquer naturais §0 §1 §2 e §3, temos\n" +"§4" + +#. §0: `le_antisymm x y` +#. §1: `x ≤ y` +#. §2: `y ≤ x` +#. §3: `x = y` +#: Game.Levels.LessOrEqual.L06le_antisymm Game.Levels.AdvMultiplication.L07mul_ne_zero +#: Game.Levels.AdvMultiplication.L09mul_left_cancel Game.Levels.AdvMultiplication.L10mul_right_eq_self +msgid "§0 is a proof that if §1 and §2 then §3." +msgstr "§0 é a prova de que se §1 e §2 então §3." + +#. §0: ``` +#. repeat rw [add_comm n] +#. exact add_right_cancel a b n +#. ``` +#: Game.Levels.AdvAddition.L02add_left_cancel +msgid "" +"How about this for a proof:\n" +"§0" +msgstr "" +"Que tal esta prova:\n" +"§0" + +#. §0: `rw [h]` +#. §1: `rfl` +#. §2: `exact h` +#: Game.Levels.Implication.L07intro2 +msgid "Now §0 then §1 works, but §2 is quicker." +msgstr "Agora §0 e depois §1 funciona, mas §2 é mais rápido." + +#. §0: `le_refl x` +#. §1: `x ≤ x` +#. §2: $\\le$ +#: Game.Levels.LessOrEqual.L01le_refl +msgid "" +"§0 is a proof of §1.\n" +"\n" +"The reason for the name is that this lemma is \"reflexivity of §2\"" +msgstr "" +"§0 é uma prova de §1.\n" +"\n" +"O motivo do nome é que este lema é a \"reflexividade de §2\"" + +#: Game.Levels.Addition.L03add_comm +msgid "add_comm (level boss)" +msgstr "add_comm (chefão)" + +#. §0: `mul_comm x y : x * y = y * x` +#. §1: `mul_zero` +#. §2: `zero_mul` +#: Game.Levels.Multiplication.L02zero_mul +msgid "" +"Our first challenge is §0,\n" +"and we want to prove it by induction. The zero\n" +"case will need §1 (which we have)\n" +"and §2 (which we don't), so let's\n" +"start with this." +msgstr "" +"Nosso primeiro desafio é §0,\n" +"e queremos provar isso por indução. O caso zero\n" +"vai precisar de §1 (que já temos)\n" +"e de §2 (que não temos), então vamos\n" +"começar por aí." + +#. §0: `simp_add` +#. §1: `a + (b + c) + (d + e) = e + (d + (c + b)) + a` +#: Game.Levels.Algorithm.L04add_algo3 +msgid "" +"# Overview\n" +"\n" +"Our home-made tactic §0 will solve arbitrary goals of\n" +"the form §1." +msgstr "" +"# Visão geral\n" +"\n" +"Nossa tática caseira §0 vai resolver objetivos arbitrários da\n" +"forma §1." + +#. §0: `20 + 20 = 40` +#: Game.Levels.Algorithm.L04add_algo3 +msgid "" +"Let's now move on to a more efficient approach to questions\n" +"involving numerals, such as §0." +msgstr "" +"Vamos agora partir para uma abordagem mais eficiente para questões\n" +"envolvendo numerais, como §0." + +#: Game.Levels.Multiplication.L09mul_assoc +msgid "" +"We now have enough to prove that multiplication is associative,\n" +"the boss level of multiplication world. Good luck!" +msgstr "" +"Agora já temos o suficiente para provar que a multiplicação é associativa,\n" +"o chefão do Mundo da Multiplicação. Boa sorte!" + +#: Game.Levels.Power.L08pow_pow +msgid "pow_pow" +msgstr "pow_pow" + +#: Game.Levels.Implication.L04succ_inj +msgid "Now finish in one line." +msgstr "Agora termine em uma linha." + +#. §0: `le_two x` +#. §1: `x ≤ 2` +#. §2: `x = 0` +#. §3: `x = 1` +#. §4: `x = 2` +#: Game.Levels.LessOrEqual.L11le_two +msgid "§0 is a proof that if §1 then §2 or §3 or §4." +msgstr "§0 é a prova de que se §1 então §2 ou §3 ou §4." + +#. §0: `Mul a b` +#. §1: `a * b` +#. §2: `mul_zero a : a * 0 = 0` +#. §3: `mul_succ a b : a * succ b = a * b + a` +#. §4: `zero_mul` +#: Game.Levels.Multiplication.L01mul_one +msgid "" +"§0, with notation §1, is the usual\n" +" product of natural numbers. Internally it is\n" +" via two axioms:\n" +"\n" +" * §2\n" +"\n" +" * §3\n" +"\n" +"Other theorems about naturals, such as §4,\n" +"are proved by induction from these two basic theorems." +msgstr "" +"§0, com a notação §1, é o produto usual\n" +" de números naturais. Internamente, ele é dado\n" +" por dois axiomas:\n" +"\n" +" * §2\n" +"\n" +" * §3\n" +"\n" +"Outros teoremas sobre os naturais, como §4,\n" +"são provados por indução a partir desses dois teoremas básicos." + +#. §0: `add_zero a` +#. §1: `a + 0 = a` +#. §2: `add_zero` +#. §3: `add_zero 37` +#. §4: `37 + 0 = 37` +#. §5: `rw` +#. §6: `rw [add_zero]` +#. §7: `add_zero` +#. §8: $\\forall n ∈ ℕ, n + 0 = n$ +#. §9: `n + 0 = n` +#: Game.Levels.Tutorial.L05add_zero +msgid "" +"§0 is a proof that §1.\n" +"\n" +"## Summary\n" +"\n" +"§2 is really a function, which\n" +"eats a number, and returns a proof of a theorem\n" +"about that number. For example §3 is\n" +"a proof that §4.\n" +"\n" +"The §5 tactic will accept §6\n" +"and will try to figure out which number you omitted\n" +"to input.\n" +"\n" +"## Details\n" +"\n" +"A mathematician sometimes thinks of §7\n" +"as \\\\\"one thing\\\\\", namely a proof of §8.\n" +"This is just another way of saying that it's a function which\n" +"can eat any number n and will return a proof that §9." +msgstr "" +"§0 é uma prova de que §1.\n" +"\n" +"## Resumo\n" +"\n" +"§2 é na verdade uma função, que\n" +"come um número e devolve uma prova de um teorema\n" +"sobre esse número. Por exemplo, §3 é\n" +"uma prova de que §4.\n" +"\n" +"A tática §5 aceita §6\n" +"e vai tentar descobrir qual número você deixou\n" +"de fornecer.\n" +"\n" +"## Detalhes\n" +"\n" +"Matemáticos às vezes pensam em §7\n" +"como \\\\\"uma coisa só\\\\\", a saber, uma prova de que §8.\n" +"Isso é apenas outra maneira de dizer que é uma função que\n" +"pode comer qualquer número n e devolver uma prova de que §9." + +#. §0: $a$ +#. §1: $b$ +#. §2: $$(a+b)^2=a^2+b^2+2ab.$$ +#: Game.Levels.Power.L09add_sq +msgid "" +"For all numbers §0 and §1, we have\n" +"§2" +msgstr "" +"Para quaisquer números §0 e §1, temos\n" +"§2" + +#. §0: `rfl` +#. §1: `rfl` +#. §2: `rfl` +#. §3: `rw` +#: Game.Levels.Tutorial.L01rfl +msgid "" +"Congratulations! You completed your first verified proof!\n" +"\n" +"Remember that §0 is a *tactic*. If you ever want information about the §1 tactic,\n" +"you can click on §2 in the list of tactics on the right.\n" +"\n" +"Now click on \"Next\" to learn about the §3 tactic." +msgstr "" +"Parabéns! Você completou sua primeira prova verificada!\n" +"\n" +"Lembre-se de que §0 é uma *tática*. Se algum dia você quiser informações sobre a tática §1,\n" +"pode clicar em §2 na lista de táticas à direita.\n" +"\n" +"Agora clique em \"Próximo\" para aprender sobre a tática §3." + +#. §0: $0+x=(0+y)+2$ +#. §1: $x=y+2$ +#: Game.Levels.Implication.L02exact2 +msgid "Assuming §0, we have §1." +msgstr "Supondo que §0, temos §1." + +#. §0: `add_right_cancel a b n` +#. §1: $a+n=b+n\\implies a=b$ +#: Game.Levels.AdvAddition.L01add_right_cancel +msgid "" +"In this world I will mostly leave you on your own.\n" +"\n" +"§0 is the theorem that §1." +msgstr "" +"Neste mundo, vou deixar você por sua própria conta na maior parte do tempo.\n" +"\n" +"§0 é o teorema de que §1." + +#: Game.Levels.Power.L06pow_add +msgid "" +"Let's now begin our approach to the final boss,\n" +"by proving some more subtle facts about powers." +msgstr "" +"Vamos agora começar a nos aproximar do chefão final,\n" +"provando alguns fatos mais sutis sobre potências." + +#. §0: `succ_le_succ x y` +#. §1: `succ x ≤ succ y` +#. §2: `x ≤ y` +#: Game.Levels.LessOrEqual.L09succ_le_succ +msgid "§0 is a proof that if §1 then §2." +msgstr "§0 é uma prova de que, se §1, então §2." + +#: Game.Levels.Implication.L08ne +msgid "≠" +msgstr "≠" + +#. §0: `c = 0` +#. §1: `c = succ e` +#. §2: `cases c with e` +#: Game.Levels.AdvMultiplication.L09mul_left_cancel +msgid "Split into cases §0 and §1 with §2." +msgstr "Divida nos casos §0 e §1 com §2." + +#. §0: `intro h` +#. §1: `h` +#: Game.Levels.Implication.L06intro +msgid "Start with §0 to assume the hypothesis and call its proof §1." +msgstr "Comece com §0 para supor a hipótese e chamar sua prova de §1." + +#: Game.Levels.AdvMultiplication.L10mul_right_eq_self +msgid "mul_right_eq_self" +msgstr "mul_right_eq_self" + +#. §0: `add_comm` +#. §1: `succ_add` +#. §2: `succ_add a b` +#. §3: `(succ a) + b = succ (a + b)` +#. §4: `a` +#. §5: `b` +#. §6: `x + y = y + x` +#. §7: `b` +#. §8: `b = 0` +#. §9: `b` +#: Game.Levels.Addition.L02succ_add +msgid "" +"Oh no! On the way to §0, a wild §1 appears. §2\n" +"is the proof that §3 for §4 and §5 numbers.\n" +"This result is what's standing in the way of §6. Again\n" +"we have the problem that we are adding §7 to things, so we need\n" +"to use induction to split into the cases where §8 and §9 is a successor." +msgstr "" +"Ah, não! No caminho para §0, um §1 selvagem aparece. §2\n" +"é a prova de que §3 para §4 e §5 números.\n" +"Esse resultado é o que está no caminho de §6. De novo\n" +"temos o problema de estarmos somando §7 às coisas, então precisamos\n" +"usar indução para separar nos casos em que §8 e em que §9 é um sucessor." + +#. §0: `simp` +#. §1: `simp` +#. §2: `add_comm` +#: Game.Levels.Algorithm.L03add_algo2 +msgid "" +"# Overview\n" +"\n" +"Lean's simplifier, §0, will rewrite every lemma\n" +"tagged with §1 and every lemma fed to it by the user, as much as it can.\n" +"Furthermore, it will attempt to order variables into an internal order if fed\n" +"lemmas such as §2, so that it does not go into an infinite loop." +msgstr "" +"# Visão geral\n" +"\n" +"O simplificador do Lean, §0, vai reescrever todo lema\n" +"marcado com §1 e todo lema passado a ele pelo usuário, o máximo que conseguir.\n" +"Além disso, ele vai tentar ordenar as variáveis segundo uma ordem interna se receber\n" +"lemas como §2, para não entrar em um loop infinito." + +#. §0: `cases ha with n hn` +#: Game.Levels.AdvMultiplication.L04one_le_of_ne_zero +msgid "Now take apart the existence statement with §0." +msgstr "Agora desmonte o enunciado de existência com §0." + +#. §0: $2+2=4$ +#: Game.Levels.Tutorial.L08twoaddtwo Game.Levels.Implication.L06intro Game.Levels.Implication.L07intro2 +#: Game.Levels.Implication.L09zero_ne_succ Game.Levels.Implication.L10one_ne_zero +#: Game.Levels.Implication.L11two_add_two_ne_five Game.Levels.Algorithm.L02add_algo1 +#: Game.Levels.Algorithm.L06is_zero Game.Levels.Algorithm.L08decide +#: Game.Levels.AdvAddition.L01add_right_cancel Game.Levels.AdvAddition.L02add_left_cancel +#: Game.Levels.AdvAddition.L04add_right_eq_self +msgid "§0." +msgstr "§0." + +#. §0: $x,y,z>0$ +#. §1: $m \\geq 3$ +#. §2: $x^m+y^m\\not =z^m$ +#. §3: $m \\geq 3$ +#. §4: `n + 3` +#. §5: `m` +#. §6: `x > 0` +#. §7: `a + 1` +#: Game.Levels.Power.L10FLT +msgid "" +"We now have enough to state a mathematically accurate, but slightly\n" +"clunky, version of Fermat's Last Theorem.\n" +"\n" +"Fermat's Last Theorem states that if §0 and §1 then §2.\n" +"If you didn't do inequality world yet then we can't talk about §3,\n" +"so we have to resort to the hack of using §4 for §5,\n" +"which guarantees it's big enough. Similarly instead of §6 we\n" +"use §7.\n" +"\n" +"This level looks superficially like other levels we have seen,\n" +"but the shortest solution known to humans would translate into\n" +"many millions of lines of Lean code. The author of this game,\n" +"Kevin Buzzard, is working on translating the proof by Wiles\n" +"and Taylor into Lean, although this task will take many years.\n" +"\n" +"## CONGRATULATIONS!\n" +"\n" +"You've finished the main quest of the natural number game!\n" +"If you would like to learn more about how to use Lean to\n" +"prove theorems in mathematics, then take a look\n" +"at [Mathematics In Lean](https://leanprover-community.github.io/mathematics_in_lean/),\n" +"an interactive textbook which you can read in your browser,\n" +"and which explains how to work with many more mathematical concepts in Lean." +msgstr "" +"Agora já temos o suficiente para enunciar uma versão matematicamente correta, mas\n" +"um pouco desajeitada, do Último Teorema de Fermat.\n" +"\n" +"O Último Teorema de Fermat diz que se §0 e §1 então §2.\n" +"Se você ainda não fez o mundo das desigualdades, não podemos falar de §3,\n" +"então temos que recorrer à gambiarra de usar §4 no lugar de §5,\n" +"o que garante que ele é grande o bastante. Da mesma forma, em vez de §6\n" +"usamos §7.\n" +"\n" +"Este nível parece, superficialmente, com outros níveis que já vimos,\n" +"mas a solução mais curta conhecida pela humanidade se traduziria em\n" +"muitos milhões de linhas de código Lean. O autor deste jogo,\n" +"Kevin Buzzard, está trabalhando em traduzir a prova de Wiles\n" +"e Taylor para Lean, embora essa tarefa vá levar muitos anos.\n" +"\n" +"## PARABÉNS!\n" +"\n" +"Você terminou a missão principal do jogo dos números naturais!\n" +"Se você quiser aprender mais sobre como usar Lean para\n" +"provar teoremas em matemática, dê uma olhada\n" +"em [Mathematics In Lean](https://leanprover-community.github.io/mathematics_in_lean/),\n" +"um livro-texto interativo que você pode ler no navegador,\n" +"e que explica como trabalhar com muitos outros conceitos matemáticos em Lean." + +#: Game.Levels.Algorithm.L09decide2 +msgid "decide again" +msgstr "decide de novo" + +#: Game.Levels.LessOrEqual.L03le_succ_self +msgid "x ≤ succ x" +msgstr "x ≤ succ x" + +#: Game.Levels.Tutorial.L02rw +msgid "Can you take it from here? Click on \"Show more help!\" if you need a hint." +msgstr "Consegue seguir daqui? Clique em \"Mostrar mais ajuda!\" se precisar de uma dica." + +#. §0: `contrapose! h` +#. §1: `succ m = succ n` +#. §2: `m = n` +#: Game.Levels.Algorithm.L07succ_ne_succ +msgid "" +"Start with §0, to change the goal into its\n" +"contrapositive, namely a hypothesis of §1 and a goal of §2." +msgstr "" +"Comece com §0, para transformar o objetivo na sua\n" +"contrapositiva, ou seja, uma hipótese §1 e um objetivo §2." + +#: Game.Levels.Multiplication.L07mul_add +msgid "mul_add" +msgstr "mul_add" + +#. §0: `a` +#. §1: `b` +#: Game.Levels.Addition.L02succ_add +msgid "" +"You might want to think about whether induction\n" +"on §0 or §1 is the best idea." +msgstr "" +"Talvez você queira pensar se indução\n" +"em §0 ou em §1 é a melhor ideia." + +#. §0: `le_trans x y z` +#. §1: `x ≤ y` +#. §2: `y ≤ z` +#. §3: `x ≤ z` +#. §4: `x ≤ y → (y ≤ z → x ≤ z)` +#. §5: $x \\le y$ +#. §6: $y \\le z$ +#. §7: $x \\le z$ +#. §8: `a + b + c` +#. §9: `(a + b) + c` +#. §10: `+` +#. §11: `→` +#. §12: `x ≤ y → y ≤ z → x ≤ z` +#. §13: `≤` +#. §14: $P \\implies Q \\implies R$ +#. §15: $P \\implies Q$ +#. §16: $Q \\implies R$ +#: Game.Levels.LessOrEqual.L04le_trans +msgid "" +"§0 is a proof that if §1 and §2 then §3.\n" +"More precisely, it is a proof that §4. In words,\n" +"If §5 then (pause) if §6 then §7.\n" +"\n" +"## A note on associativity\n" +"\n" +"In Lean, §8 means §9, because §10 is left associative. However\n" +"§11 is right associative. This means that §12 in Lean means\n" +"exactly that §13 is transitive. This is different to how mathematicians use\n" +"§14; for them, this usually means that §15\n" +"and §16." +msgstr "" +"§0 é uma prova de que se §1 e §2, então §3.\n" +"Mais precisamente, é a prova de que §4. Em palavras,\n" +"se §5 então (pausa) se §6 então §7.\n" +"\n" +"## Uma observação sobre associatividade\n" +"\n" +"Em Lean, §8 significa §9, porque §10 é associativo à esquerda. Já\n" +"§11 é associativo à direita. Isso significa que §12 em Lean quer dizer\n" +"exatamente que §13 é transitiva. Isso é diferente de como os matemáticos usam\n" +"§14; para eles, isso normalmente significa que §15\n" +"e §16." + +#: Game.Levels.Algorithm.L02add_algo1 +msgid "making life easier" +msgstr "facilitando a vida" + +#. §0: `add_succ` +#: Game.Levels.Addition.L01zero_add +msgid "Use §0." +msgstr "Use §0." + +#. §0: `or` +#. §1: `right` +#: Game.Levels.LessOrEqual.L07or_symm +msgid "" +"Now we can prove the §0 statement by proving the statement on the right,\n" +"so use the §1 tactic." +msgstr "" +"Agora podemos provar o enunciado com §0 provando o enunciado da direita,\n" +"então use a tática §1." + +#. §0: `h : a ≠ b` +#. §1: `c ≠ d` +#. §2: `contrapose! h` +#. §3: `h : c = d` +#. §4: `a = b` +#: Game.Levels.Algorithm.L07succ_ne_succ +msgid "" +"# Summary\n" +"\n" +"If you have a hypothesis\n" +"\n" +"§0\n" +"\n" +"and goal\n" +"\n" +"§1\n" +"\n" +"then §2 replaces the set-up with its so-called \\\\\"contrapositive\\\\\":\n" +"a hypothesis\n" +"\n" +"§3\n" +"\n" +"and goal\n" +"\n" +"§4." +msgstr "" +"# Resumo\n" +"\n" +"Se você tem uma hipótese\n" +"\n" +"§0\n" +"\n" +"e o objetivo\n" +"\n" +"§1\n" +"\n" +"então §2 substitui essa configuração pela sua chamada \\\\\"contrapositiva\\\\\":\n" +"uma hipótese\n" +"\n" +"§3\n" +"\n" +"e o objetivo\n" +"\n" +"§4." + +#. §0: `succ_add a b` +#. §1: `succ a + b = succ (a + b)` +#: Game.Levels.Addition.L02succ_add Game.Levels.Multiplication.L08add_mul Game.Levels.Power.L04one_pow +#: Game.Levels.Implication.L10one_ne_zero Game.Levels.Algorithm.L01add_left_comm +#: Game.Levels.LessOrEqual.L02zero_le Game.Levels.LessOrEqual.L03le_succ_self +#: Game.Levels.AdvMultiplication.L01mul_le_mul_right Game.Levels.AdvMultiplication.L02mul_left_ne_zero +#: Game.Levels.AdvMultiplication.L03eq_succ_of_ne_zero Game.Levels.AdvMultiplication.L04one_le_of_ne_zero +#: Game.Levels.AdvMultiplication.L06mul_right_eq_one +msgid "§0 is a proof that §1." +msgstr "§0 é uma prova de que §1." + +#: Game.Levels.AdvMultiplication.L03eq_succ_of_ne_zero +msgid "eq_succ_of_ne_zero" +msgstr "eq_succ_of_ne_zero" + +#. §0: ``` +#. induction c with d hd +#. rw [add_zero, mul_zero, add_zero] +#. rfl +#. rw [add_succ, mul_succ, hd, mul_succ, add_assoc] +#. rfl +#. ``` +#. §1: `a` +#. §2: `b` +#: Game.Levels.Multiplication.L07mul_add +msgid "" +"Here's my solution:\n" +"§0\n" +"\n" +"Inducting on §1 or §2 also works, but might take longer." +msgstr "" +"Aqui está a minha solução:\n" +"§0\n" +"\n" +"Fazer indução em §1 ou §2 também funciona, mas pode dar mais trabalho." + +#. §0: `apply succ_inj` +#. §1: `succ_inj` +#: Game.Levels.Implication.L05succ_inj2 +msgid "Start with §0 to apply §1 to the *goal*." +msgstr "Comece com §0 para aplicar §1 ao *objetivo*." + +#: Game.Levels.Multiplication.L02zero_mul +msgid "zero_mul" +msgstr "zero_mul" + +#: Game.Levels.Tutorial.L03two_eq_ss0 +msgid "Can you take it from here?" +msgstr "Consegue continuar daqui?" + +#: Game.Levels.Power.L07mul_pow +msgid "mul_pow" +msgstr "mul_pow" + +#. §0: `≤` +#. §1: `ℕ` +#: Game.Levels.LessOrEqual.L04le_trans +msgid "" +"A passing mathematician remarks that with reflexivity and transitivity out of the way,\n" +"you have proved that §0 is a *preorder* on §1." +msgstr "" +"Um matemático que passava por ali comenta que, com a reflexividade e a transitividade resolvidas,\n" +"você provou que §0 é uma *pré-ordem* em §1." + +#. §0: ``` +#. cases hxy with a ha +#. cases hyx with b hb +#. rw [ha] +#. rw [ha, add_assoc] at hb +#. symm at hb +#. apply add_right_eq_self at hb +#. apply add_right_eq_zero at hb +#. rw [hb, add_zero] +#. rfl +#. ``` +#. §1: `≤` +#. §2: `ℕ` +#. §3: `≤` +#: Game.Levels.LessOrEqual.L06le_antisymm +msgid "" +"Here's my proof:\n" +"§0\n" +"\n" +"A passing mathematician remarks that with antisymmetry as well,\n" +"you have proved that §1 is a *partial order* on §2.\n" +"\n" +"The boss level of this world is to prove\n" +"that §3 is a total order. Let's learn two more easy tactics\n" +"first." +msgstr "" +"Aqui está a minha prova:\n" +"§0\n" +"\n" +"Um matemático que passava por aqui observa que, junto com a antissimetria,\n" +"você provou que §1 é uma *ordem parcial* em §2.\n" +"\n" +"O chefão deste mundo é provar\n" +"que §3 é uma ordem total. Vamos aprender mais duas táticas fáceis\n" +"antes disso." + +#: Game.Levels.Multiplication.L05one_mul +msgid "one_mul" +msgstr "one_mul" + +#. §0: `«{hd}» : 0 + «{d}» = «{d}»` +#. §1: `0 + succ «{d}» = succ «{d}»` +#: Game.Levels.Addition.L01zero_add +msgid "" +"Now for the second goal. Here you have the induction hypothesis\n" +"§0, and you need to prove that §1." +msgstr "" +"Agora o segundo objetivo. Aqui você tem a hipótese de indução\n" +"§0, e precisa provar que §1." + +#: Game.Levels.Algorithm.L05pred +msgid "pred" +msgstr "pred" + +#. §0: `exact` +#: Game.Levels.Implication.L01exact Game.Levels.LessOrEqual.L01le_refl +msgid "The §0 tactic" +msgstr "A tática §0" + +#. §0: `succ n` +#. §1: `n + 1` +#: Game.Levels.Tutorial.L04rw_backwards +msgid "" +"Why did we not just define §0 to be §1? Because we have not\n" +"even *defined* addition yet! We'll do that in the next level." +msgstr "" +"Por que não definimos logo §0 como §1? Porque ainda nem\n" +"*definimos* a adição! Vamos fazer isso no próximo nível." + +#. §0: $x$ +#. §1: $y$ +#. §2: $y = x + 7$ +#. §3: $2y = 2(x + 7)$ +#: Game.Levels.Tutorial.L02rw +msgid "If §0 and §1 are natural numbers, and §2, then §3." +msgstr "Se §0 e §1 são números naturais, e §2, então §3." + +#: Game.Levels.Power.L09add_sq +msgid "[final boss music]" +msgstr "[música de chefão final]" + +#. §0: `succ_eq_add_one n` +#. §1: `succ n = n + 1` +#: Game.Levels.Tutorial.L07add_succ Game.Levels.Multiplication.L01mul_one +#: Game.Levels.Multiplication.L06two_mul Game.Levels.Algorithm.L07succ_ne_succ +msgid "§0 is the proof that §1." +msgstr "§0 é a prova de que §1." + +#: Game.Levels.Addition.L05add_right_comm +msgid "add_right_comm" +msgstr "add_right_comm" + +#. §0: `add_zero` +#: Game.Levels.Addition.L01zero_add +msgid "try rewriting §0." +msgstr "tente reescrever §0." + +#: Game.Levels.AdvMultiplication.L04one_le_of_ne_zero +msgid "one_le_of_ne_zero" +msgstr "one_le_of_ne_zero" + +#. §0: `add_right_cancel a b n` +#. §1: $a+n=b+n \\implies a=b.$ +#: Game.Levels.AdvAddition.L01add_right_cancel Game.Levels.AdvAddition.L02add_left_cancel +#: Game.Levels.AdvAddition.L03add_left_eq_self Game.Levels.AdvAddition.L04add_right_eq_self +msgid "§0 is the theorem that §1" +msgstr "§0 é o teorema de que §1" + +#: Game.Levels.Power.L04one_pow +msgid "one_pow" +msgstr "one_pow" + +#. §0: $a, b, c$ +#. §1: $a+(b+c)=b+(a+c)$ +#: Game.Levels.Algorithm.L01add_left_comm +msgid "If §0 are numbers, then §1." +msgstr "Se §0 são números, então §1." + +#. §0: `a ≤ b` +#. §1: `∃ c, b = a + c` +#. §2: `a ≤ b` +#. §3: `c` +#. §4: `b = a + c` +#. §5: `use` +#: Game.Levels.LessOrEqual.L01le_refl +msgid "" +"§0 is *notation* for §1. This \"backwards E\"\n" +"means \"there exists\". So §2 means that there exists\n" +"a number §3 such that §4. This definition works\n" +"because there are no negative numbers in this game.\n" +"\n" +"To *prove* an \"exists\" statement, use the §5 tactic.\n" +"Let's see an example." +msgstr "" +"§0 é *notação* para §1. Esse \"E ao contrário\"\n" +"significa \"existe\". Então §2 quer dizer que existe\n" +"um número §3 tal que §4. Essa definição funciona\n" +"porque não há números negativos neste jogo.\n" +"\n" +"Para *provar* um enunciado de existência, use a tática §5.\n" +"Vamos ver um exemplo." + +#: Game.Levels.LessOrEqual.L02zero_le +msgid "0 ≤ x" +msgstr "0 ≤ x" + +#. §0: `or` +#: Game.Levels.LessOrEqual.L07or_symm +msgid "Dealing with §0" +msgstr "Lidando com §0" + +#: Game.Levels.Multiplication.L08add_mul +msgid "add_mul" +msgstr "add_mul" + +#. §0: `apply eq_succ_of_ne_zero at ha` +#. §1: `... at hb` +#: Game.Levels.AdvMultiplication.L07mul_ne_zero +msgid "Start with §0 and §1" +msgstr "Comece com §0 e §1" + +#. §0: `pow_succ a b : a ^ (succ b) = a ^ b * a` +#: Game.Levels.Power.L02zero_pow_succ +msgid "" +"§0 is one of the\n" +"two axioms defining exponentiation in this game." +msgstr "" +"§0 é um dos\n" +"dois axiomas que definem a exponenciação neste jogo." + +#. §0: `mul_zero` +#. §1: `mul_succ` +#. §2: `1` +#: Game.Levels.Multiplication.L01mul_one +msgid "" +"See the new \"*\" tab in your lemmas, containing §0 and §1.\n" +"Right now these are the only facts we know about multiplication.\n" +"Let's prove nine more.\n" +"\n" +"Let's start with a warm-up: no induction needed for this one,\n" +"because we know §2 is a successor." +msgstr "" +"Veja a nova aba \"*\" nos seus lemas, contendo §0 e §1.\n" +"Neste momento esses são os únicos fatos que conhecemos sobre multiplicação.\n" +"Vamos provar mais nove.\n" +"\n" +"Comecemos com um aquecimento: não é preciso indução para este,\n" +"porque sabemos que §2 é um sucessor." + +#: Game.Levels.Implication.L09zero_ne_succ Game.Levels.AdvAddition.L01add_right_cancel +msgid "Nice!" +msgstr "Muito bem!" + +#. §0: $m$ +#. §1: $ m \\times 1 = m$ +#: Game.Levels.Multiplication.L01mul_one Game.Levels.Multiplication.L05one_mul +#: Game.Levels.Multiplication.L06two_mul +msgid "For any natural number §0, we have §1." +msgstr "Para qualquer número natural §0, temos §1." + +#. §0: `rw [h]` +#. §1: `y` +#. §2: `x + 7` +#: Game.Levels.Tutorial.L02rw +msgid "First execute §0 to replace the §1 with §2." +msgstr "Primeiro execute §0 para substituir §1 por §2." + +#. §0: $2+2=4$ +#. §1: $2+2\\neq 5$ +#. §2: $x + y = y + x$ +#. §3: $x+1=4 \\implies x=3.$ +#: Game.Levels.Implication +msgid "" +"We've proved that §0; in Implication World we'll learn\n" +"how to prove §1.\n" +"\n" +"In Addition World we proved *equalities* like §2.\n" +"In this second tutorial world we'll learn some new tactics,\n" +"enabling us to prove *implications*\n" +"like §3\n" +"\n" +"We'll also learn two new fundamental facts about\n" +"natural numbers, which Peano introduced as axioms.\n" +"\n" +"Click on \"Start\" to proceed." +msgstr "" +"Provamos que §0; no Mundo da Implicação vamos aprender\n" +"como provar §1.\n" +"\n" +"No Mundo da Adição provamos *igualdades* como §2.\n" +"Neste segundo mundo tutorial vamos aprender algumas táticas novas,\n" +"que nos permitirão provar *implicações*\n" +"como §3\n" +"\n" +"Também vamos aprender dois novos fatos fundamentais sobre\n" +"os números naturais, que Peano introduziu como axiomas.\n" +"\n" +"Clique em \"Começar\" para continuar." + +#: Game.Levels.LessOrEqual.L11le_two +msgid "le_two" +msgstr "le_two" + +#: Game.Levels.Power.L05pow_two +msgid "pow_two" +msgstr "pow_two" + +#. §0: ``` +#. have h2 := mul_ne_zero a b +#. tauto +#. ``` +#. §1: `mul_ne_zero a b` +#: Game.Levels.AdvMultiplication.L08mul_eq_zero +msgid "" +"Here's the short proof:\n" +"§0\n" +"This works because, given §1,\n" +"the argument is reduced to pure logic." +msgstr "" +"Aqui está a prova curta:\n" +"§0\n" +"Isso funciona porque, dado §1,\n" +"o argumento se reduz a pura lógica." + +#. §0: `rw [← pred_succ a]` +#: Game.Levels.Algorithm.L05pred +msgid "Start with §0 and take it from there." +msgstr "Comece com §0 e siga a partir daí." + +#. §0: `0` +#. §1: `pred` +#. §2: ``` +#. pred 0 := 37 +#. pred (succ n) := n +#. ``` +#. §3: `pred_succ` +#. §4: `pred (succ n) = n` +#. §5: `succ_inj` +#: Game.Levels.Algorithm.L05pred +msgid "" +"We now start work on an algorithm to do addition more efficiently. Recall that\n" +"we defined addition by recursion, saying what it did on §0 and successors.\n" +"It is an axiom of Lean that recursion is a valid\n" +"way to define functions from types such as the naturals.\n" +"\n" +"Let's define a new function §1 from the naturals to the naturals, which\n" +"attempts to subtract 1 from the input. The definition is this:\n" +"\n" +"§2\n" +"\n" +"We cannot subtract one from 0, so we just return a junk value. As well as this\n" +"definition, we also create a new lemma §3, which says that §4.\n" +"Let's use this lemma to prove §5, the theorem which\n" +"Peano assumed as an axiom and which we have already used extensively without justification." +msgstr "" +"Agora começamos a trabalhar em um algoritmo para fazer adição de forma mais eficiente. Lembre-se de " +"que\n" +"definimos a adição por recursão, dizendo o que ela faz em §0 e em sucessores.\n" +"É um axioma de Lean que a recursão é uma maneira válida\n" +"de definir funções a partir de tipos como os naturais.\n" +"\n" +"Vamos definir uma nova função §1 dos naturais nos naturais, que\n" +"tenta subtrair 1 da entrada. A definição é esta:\n" +"\n" +"§2\n" +"\n" +"Não podemos subtrair um de 0, então simplesmente devolvemos um valor lixo. Além dessa\n" +"definição, também criamos um novo lema §3, que diz que §4.\n" +"Vamos usar esse lema para provar §5, o teorema que\n" +"Peano presumiu como axioma e que já usamos bastante sem justificativa." + +#: Game.Levels.Algorithm.L06is_zero +msgid "is_zero" +msgstr "is_zero" + +#. §0: $a$ +#. §1: $b$ +#. §2: $c$ +#. §3: $(ab)c = a(bc)$ +#: Game.Levels.Multiplication.L09mul_assoc +msgid "" +"Multiplication is associative.\n" +"In other words, for all natural numbers §0, §1 and §2, we have\n" +"§3." +msgstr "" +"A multiplicação é associativa.\n" +"Em outras palavras, para quaisquer números naturais §0, §1 e §2, temos\n" +"§3." + +#. §0: `simp` +#. §1: `rw` +#. §2: `simp` +#: Game.Levels.Algorithm.L03add_algo2 +msgid "" +"Lean's simplifier, §0, is \"§1 on steroids\". It will rewrite every lemma\n" +"tagged with §2 and every lemma fed to it by the user, as much as it can.\n" +"\n" +"This level is not a level which you want to solve by hand.\n" +"Get the simplifier to solve it for you." +msgstr "" +"O simplificador de Lean, §0, é o \"§1 turbinado\". Ele vai reescrever todo lema\n" +"marcado com §2 e todo lema fornecido pelo usuário, tanto quanto conseguir.\n" +"\n" +"Este nível não é um nível que você queira resolver na mão.\n" +"Faça o simplificador resolvê-lo para você." + +#. §0: `h : X = Y` +#. §1: `X` +#. §2: `nth_rewrite 3 [h]` +#. §3: `X` +#. §4: `Y` +#. §5: `2 + 2 = 4` +#. §6: `nth_rewrite 2 [two_eq_succ_one]` +#. §7: `2 + succ 1 = 4` +#. §8: `rw [two_eq_succ_one]` +#. §9: `succ 1 + succ 1 = 4` +#: Game.Levels.Tutorial.L02rw +msgid "" +"## Summary\n" +"\n" +"If §0 and there are several §1s in the goal, then\n" +"§2 will just change the third §3 to a §4.\n" +"\n" +"## Example\n" +"\n" +"If the goal is §5 then §6\n" +"will change the goal to §7. In contrast, §8\n" +"will change the goal to §9." +msgstr "" +"## Resumo\n" +"\n" +"Se §0 e há vários §1 no objetivo, então\n" +"§2 vai mudar apenas o terceiro §3 para §4.\n" +"\n" +"## Exemplo\n" +"\n" +"Se o objetivo é §5 então §6\n" +"vai mudar o objetivo para §7. Em contraste, §8\n" +"vai mudar o objetivo para §9." + +#. §0: $P\\implies Q$ +#. §1: $Q$ +#. §2: $P$ +#. §3: `rw [succ_eq_add_one]` +#: Game.Levels.Implication.L05succ_inj2 +msgid "" +"Applying a proof of §0 to the *goal* changes §1 to §2.\n" +"Now try §3 to make the goal more like the hypothesis." +msgstr "" +"Aplicar uma prova de §0 ao *objetivo* transforma §1 em §2.\n" +"Agora tente fazer §3 para deixar o objetivo mais parecido com a hipótese." + +#. §0: $a$ +#. §1: $b$ +#. §2: $(\\operatorname{succ}\\ a) \\times b = a\\times b + b$ +#: Game.Levels.Multiplication.L03succ_mul +msgid "" +"For all natural numbers §0 and §1, we have\n" +"§2." +msgstr "" +"Para quaisquer números naturais §0 e §1, temos\n" +"§2." + +#. §0: $a+b=0 \\implies a=0$ +#: Game.Levels.AdvAddition.L05add_right_eq_zero Game.Levels.AdvAddition.L06add_left_eq_zero +msgid "A proof that §0." +msgstr "Uma prova de que §0." + +#. §0: `repeat rw [add_assoc]` +#: Game.Levels.Algorithm.L02add_algo1 +msgid "Start with §0 to push all the brackets to the right." +msgstr "Comece com §0 para empurrar todos os parênteses para a direita." + +#. §0: `cases a with d` +#. §1: `a = 0` +#. §2: `a = succ d` +#: Game.Levels.AdvMultiplication.L03eq_succ_of_ne_zero +msgid "Start with §0 to do a case split on §1 and §2." +msgstr "Comece com §0 para fazer uma divisão em casos entre §1 e §2." + +#. §0: `mul_eq_zero` +#. §1: `tauto` +#. §2: `a = 0` +#. §3: `a ≠ 0` +#: Game.Levels.AdvMultiplication.L09mul_left_cancel +msgid "" +"Use §0 and remember that §1 will solve a goal\n" +"if there are hypotheses §2 and §3." +msgstr "" +"Use §0 e lembre que §1 resolve um objetivo\n" +"se houver hipóteses §2 e §3." + +#: Game.Levels.AdvMultiplication.L04one_le_of_ne_zero +msgid "The previous lemma can be used to prove this one." +msgstr "O lema anterior pode ser usado para provar este." + +#. §0: `is_zero` +#. §1: ``` +#. is_zero 0 := True +#. is_zero (succ n) := False +#. ``` +#. §2: `is_zero_zero` +#. §3: `is_zero_succ n` +#. §4: `is_zero 0 = True` +#. §5: `is_zero (succ n) = False` +#. §6: `succ_ne_zero` +#. §7: `zero_ne_succ` +#. §8: `zero_ne_succ` +#. §9: `True` +#. §10: `trivial` +#: Game.Levels.Algorithm.L06is_zero +msgid "" +"We define a function §0 thus:\n" +"\n" +"§1\n" +"\n" +"We also create two lemmas, §2 and §3, saying that §4\n" +"and §5. Let's use these lemmas to prove §6, Peano's\n" +"Last Axiom. Actually, we have been using §7 before, but it's handy to have\n" +"this opposite version too, which can be proved in the same way. Note: you can\n" +"cheat here by using §8 but the point of this world is to show\n" +"you how to *prove* results like that.\n" +"\n" +"If you can turn your goal into §9, then the §10 tactic will solve it." +msgstr "" +"Definimos uma função §0 assim:\n" +"\n" +"§1\n" +"\n" +"Também criamos dois lemas, §2 e §3, dizendo que §4\n" +"e §5. Vamos usar esses lemas para provar §6, o Último\n" +"Axioma de Peano. Na verdade, já usamos §7 antes, mas é útil ter\n" +"esta versão oposta também, que pode ser provada da mesma forma. Nota: você pode\n" +"trapacear aqui usando §8, mas a ideia deste mundo é mostrar\n" +"como *provar* resultados desse tipo.\n" +"\n" +"Se você conseguir transformar seu objetivo em §9, então a tática §10 vai resolvê-lo." + +#: Game.Levels.AdvMultiplication.L08mul_eq_zero +msgid "mul_eq_zero" +msgstr "mul_eq_zero" + +#. §0: `rw [two_eq_succ_one]` +#. §1: `2` +#: Game.Levels.Tutorial.L03two_eq_ss0 +msgid "Start with §0 to begin to break §1 down into its definition." +msgstr "Comece com §0 para começar a decompor §1 na sua definição." + +#: Game.Levels.Implication.L10one_ne_zero +msgid "1 ≠ 0" +msgstr "1 ≠ 0" + +#: Game.Levels.AdvMultiplication.L01mul_le_mul_right +msgid "mul_le_mul_right" +msgstr "mul_le_mul_right" + +#: Game.Levels.AdvAddition.L04add_right_eq_self +msgid "add_right_eq_self" +msgstr "add_right_eq_self" + +#. §0: `2 + 2 ≠ 5` +#. §1: `≠` +#. §2: `a ≠ b` +#. §3: `a = b → False` +#. §4: `False` +#. §5: `→` +#. §6: `True → False` +#. §7: `False → False` +#. §8: `X → False` +#. §9: `X` +#. §10: `a ≠ b` +#. §11: `False` +#. §12: `False` +#: Game.Levels.Implication.L08ne +msgid "" +"We still can't prove §0 because we have not talked about the\n" +"definition of §1. In Lean, §2 is *notation* for §3.\n" +"Here §4 is a generic false proposition, and §5 is Lean's notation\n" +"for \"implies\". In logic we learn\n" +"that §6 is false, but §7 is true. Hence\n" +"§8 is the logical opposite of §9.\n" +"\n" +"Even though §10 does not look like an implication,\n" +"you should treat it as an implication. The next two levels will show you how.\n" +"\n" +"§11 is a goal which you cannot deduce from a consistent set of assumptions!\n" +"So if your goal is §12 then you had better hope that your hypotheses\n" +"are contradictory, which they are in this level." +msgstr "" +"Ainda não podemos provar §0 porque não falamos sobre a\n" +"definição de §1. Em Lean, §2 é *notação* para §3.\n" +"Aqui §4 é uma proposição falsa genérica, e §5 é a notação de Lean\n" +"para \"implica\". Em lógica aprendemos\n" +"que §6 é falso, mas §7 é verdadeiro. Logo,\n" +"§8 é o oposto lógico de §9.\n" +"\n" +"Mesmo que §10 não pareça uma implicação,\n" +"você deve tratá-lo como uma implicação. Os dois próximos níveis vão te mostrar como.\n" +"\n" +"§11 é um objetivo que você não consegue deduzir de um conjunto consistente de hipóteses!\n" +"Então, se seu objetivo é §12, é melhor torcer para que suas hipóteses\n" +"sejam contraditórias, o que é o caso neste nível." + +#: Game.Levels.LessOrEqual.L04le_trans +msgid "x ≤ y and y ≤ z implies x ≤ z" +msgstr "x ≤ y e y ≤ z implica x ≤ z" + +#. §0: `exact` +#: Game.Levels.Implication.L02exact2 +msgid "§0 practice." +msgstr "Praticando §0." + +#. §0: `zero_ne_succ n` +#. §1: `0 = succ n → False` +#. §2: `succ n = 0` +#. §3: `symm` +#. §4: `x = y` +#. §5: `y = x` +#. §6: `x ≠ y` +#. §7: `y ≠ x` +#. §8: `symm at h` +#. §9: `h` +#. §10: $0 \\neq 1$ +#. §11: `zero_ne_one` +#. §12: $1 \\neq 0$ +#: Game.Levels.Implication.L10one_ne_zero +msgid "" +"We know §0 is a proof of §1 -- but what\n" +"if we have a hypothesis §2? It's the wrong way around!\n" +"\n" +"The §3 tactic changes a goal §4 to §5, and a goal §6\n" +"to §7. And §8\n" +"does the same for a hypothesis §9. We've proved §10 and called\n" +"the proof §11; now try proving §12." +msgstr "" +"Sabemos que §0 é uma prova de §1 -- mas e\n" +"se tivermos uma hipótese §2? Está ao contrário!\n" +"\n" +"A tática §3 muda um objetivo §4 para §5, e um objetivo §6\n" +"para §7. E §8\n" +"faz o mesmo para uma hipótese §9. Já provamos §10 e chamamos\n" +"a prova de §11; agora tente provar §12." + +#: Game.Levels.Addition.L02succ_add +msgid "Well done! You now have enough tools to tackle the main boss of this level." +msgstr "Muito bem! Agora você tem ferramentas suficientes para enfrentar o chefão principal deste nível." + +#. §0: `use` +#. §1: `use` +#: Game.Levels.LessOrEqual.L03le_succ_self +msgid "" +"If you §0 the wrong number, you get stuck with a goal you can't prove.\n" +"What number will you §1 here?" +msgstr "" +"Se você usar §0 com o número errado, fica preso com um objetivo que não consegue provar.\n" +"Qual número você vai usar no §1 aqui?" + +#: Game.Levels.Multiplication.L04mul_comm +msgid "Multiplication is commutative." +msgstr "A multiplicação é comutativa." + +#. §0: `mul_succ` +#. §1: `succ_mul` +#: Game.Levels.Multiplication.L03succ_mul +msgid "" +"Similarly we have §0\n" +"but we're going to need §1 (guess what it says -- maybe you\n" +"are getting the hang of Lean's naming conventions).\n" +"\n" +"The last level from addition world might help you in this level.\n" +"If you can't remember what it is, you can go back to the\n" +"home screen by clicking the house icon and then taking a look.\n" +"You won't lose any progress." +msgstr "" +"De modo semelhante, temos §0,\n" +"mas vamos precisar de §1 (adivinhe o que ele diz -- talvez você\n" +"esteja pegando o jeito das convenções de nomes de Lean).\n" +"\n" +"O último nível do Mundo da Adição pode te ajudar neste nível.\n" +"Se você não lembra qual é, pode voltar para a\n" +"tela inicial clicando no ícone da casa e dar uma olhada.\n" +"Você não vai perder nenhum progresso." + +#. §0: `intro h` +#: Game.Levels.Implication.L09zero_ne_succ Game.Levels.LessOrEqual.L04le_trans +#: Game.Levels.LessOrEqual.L08le_total Game.Levels.AdvMultiplication.L02mul_left_ne_zero +#: Game.Levels.AdvMultiplication.L08mul_eq_zero +msgid "Start with §0." +msgstr "Comece com §0." + +#: Game.Levels.Multiplication.L03succ_mul +msgid "succ_mul" +msgstr "succ_mul" + +#. §0: `add_left_comm` +#. §1: `rw [add_comm b c]` +#. §2: `a + b + c` +#. §3: `(a + b) + c` +#: Game.Levels.Algorithm.L01add_left_comm +msgid "" +"Having to rearrange variables manually using commutativity and\n" +"associativity is very tedious. We start by reminding you of this. §0\n" +"is a key component in the first algorithm which we'll explain, but we need\n" +"to prove it manually.\n" +"\n" +"Remember that you can do precision commutativity rewriting\n" +"with things like §1. And remember that\n" +"§2 means §3." +msgstr "" +"Ter que rearranjar variáveis manualmente usando comutatividade e\n" +"associatividade é bem tedioso. Começamos te lembrando disso. §0\n" +"é uma peça-chave no primeiro algoritmo que vamos explicar, mas precisamos\n" +"prová-lo manualmente.\n" +"\n" +"Lembre que você pode fazer reescrita de comutatividade com precisão\n" +"com coisas como §1. E lembre que\n" +"§2 significa §3." + +#: Game.Levels.Tutorial.L03two_eq_ss0 +msgid "Numbers" +msgstr "Números" + +#. §0: `rfl` +#: Game.Levels.Tutorial.L07add_succ +msgid "And finally §0." +msgstr "E finalmente §0." + +#. §0: `37 * x` +#. §1: $x=0$ +#. §2: $x$ +#. §3: `37 * 0` +#. §4: `0` +#. §5: `37 * d` +#. §6: `37 * succ d` +#. §7: $(d+1)$ +#. §8: $37$ +#. §9: `37 * d + 37` +#. §10: `mul_zero a : a * 0 = 0` +#. §11: `mul_succ a d : a * succ d = a * d + a` +#. §12: `a * b = b * a` +#. §13: `a * (b + c) = a * b + a * c` +#: Game.Levels.Multiplication +msgid "" +"How should we define §0? Just like addition, we need to give definitions\n" +"when §1 and when §2 is a successor.\n" +"\n" +"The zero case is easy: we define §3 to be §4. Now say we know\n" +"§5. What should §6 be? Well, that's §7 §8s,\n" +"so it should be §9.\n" +"\n" +"Here are the definitions in Lean.\n" +"\n" +" * §10\n" +" * §11\n" +"\n" +"In this world, we must not only prove facts about multiplication like §12,\n" +"we must also prove facts about how multiplication interacts with addition, like §13.\n" +"Let's get started." +msgstr "" +"Como devemos definir §0? Assim como na adição, precisamos dar definições\n" +"para quando §1 e para quando §2 é um sucessor.\n" +"\n" +"O caso zero é fácil: definimos §3 como §4. Agora suponha que sabemos\n" +"§5. Quanto deveria ser §6? Bem, isso é §7 §8s,\n" +"então deveria ser §9.\n" +"\n" +"Aqui estão as definições em Lean.\n" +"\n" +" * §10\n" +" * §11\n" +"\n" +"Neste mundo, não devemos apenas provar fatos sobre multiplicação como §12,\n" +"devemos também provar fatos sobre como a multiplicação interage com a adição, como §13.\n" +"Vamos começar." + +#. §0: $2y=2(x+7)$ +#. §1: `h` +#. §2: $y = x + 7$ +#. §3: `h` +#. §4: `h` +#. §5: `x` +#. §6: `rfl` +#. §7: $y$ +#. §8: `h` +#. §9: `rw` +#: Game.Levels.Tutorial.L02rw +msgid "" +"In this level the *goal* is §0 but to help us we\n" +"have an *assumption* §1 saying that §2. Check that you can see §3 in\n" +"your list of assumptions. Lean thinks of §4 as being a secret proof of the\n" +"assumption, rather like §5 is a secret number.\n" +"\n" +"Before we can use §6, we have to \"substitute in for §7\".\n" +"We do this in Lean by *rewriting* the proof §8,\n" +"using the §9 tactic." +msgstr "" +"Neste nível o *objetivo* é §0, mas para nos ajudar temos\n" +"uma *hipótese* §1 dizendo que §2. Verifique que você consegue ver §3 na\n" +"sua lista de hipóteses. O Lean pensa em §4 como uma prova secreta da\n" +"hipótese, mais ou menos como §5 é um número secreto.\n" +"\n" +"Antes de podermos usar §6, temos que \"substituir §7\".\n" +"Fazemos isso em Lean *reescrevendo* usando a prova §8,\n" +"com a tática §9." + +#. §0: ``` +#. symm +#. exact zero_ne_one +#. ``` +#. §1: `exact` +#: Game.Levels.Implication.L10one_ne_zero +msgid "" +"What do you think of this two-liner:\n" +"§0\n" +"\n" +"§1 doesn't just take hypotheses, it will eat any proof which exists\n" +"in the system." +msgstr "" +"O que você acha destas duas linhas:\n" +"§0\n" +"\n" +"§1 não aceita apenas hipóteses, ele engole qualquer prova que exista\n" +"no sistema." + +#: Game.Levels.LessOrEqual.L09succ_le_succ +msgid "succ x ≤ succ y → x ≤ y" +msgstr "succ x ≤ succ y → x ≤ y" + +#: Game +msgid "The classical introduction game for Lean." +msgstr "O clássico jogo para conhecer o Lean." + +#. §0: `rw [«{h}»]` +#. §1: `rfl` +#. §2: `exact «{h}»` +#: Game.Levels.Implication.L02exact2 +msgid "" +"Now you could finish with §0 then §1, but §2\n" +"does it in one line." +msgstr "" +"Agora você poderia terminar com §0 e depois §1, mas §2\n" +"faz isso em uma linha só." + +#: Game.Levels.Power.L10FLT +msgid "Fermat's Last Theorem" +msgstr "Último Teorema de Fermat" + +#. §0: `apply` +#. §1: `P → Q` +#. §2: `P → Q` +#. §3: `P` +#. §4: `Q` +#. §5: `intro` +#: Game.Levels.Implication.L06intro +msgid "" +"We have seen how to §0 theorems and assumptions\n" +"of the form §1. But what if our *goal* is of the form §2?\n" +"To prove this goal, we need to know how to say \"let's assume §3 and deduce §4\"\n" +"in Lean. We do this with the §5 tactic." +msgstr "" +"Já vimos como usar §0 em teoremas e hipóteses\n" +"da forma §1. Mas e se o nosso *objetivo* for da forma §2?\n" +"Para provar esse objetivo, precisamos saber como dizer \"vamos supor §3 e deduzir §4\"\n" +"em Lean. Fazemos isso com a tática §5." + +#. §0: $x$ +#. §1: $x \\le x$ +#: Game.Levels.LessOrEqual.L01le_refl Game.Levels.LessOrEqual.L02zero_le +#: Game.Levels.LessOrEqual.L03le_succ_self +msgid "If §0 is a number, then §1." +msgstr "Se §0 é um número, então §1." + +#. §0: ``` +#. cases x with y +#. left +#. rfl +#. rw [one_eq_succ_zero] at hx ⊢ +#. apply succ_le_succ at hx +#. apply le_zero at hx +#. rw [hx] +#. right +#. rfl +#. ``` +#: Game.Levels.LessOrEqual.L10le_one +msgid "" +"Here's my proof:\n" +"§0\n" +"\n" +"If you solved this level then you should be fine with the next level!" +msgstr "" +"Aqui está a minha prova:\n" +"§0\n" +"\n" +"Se você resolveu este nível, então vai se dar bem no próximo!" + +#. §0: `2 = 2` +#: Game.Levels.Tutorial.L04rw_backwards +msgid "Can you now change the goal into §0?" +msgstr "Agora você consegue transformar o objetivo em §0?" + +#: Game.Levels.Power.L09add_sq +msgid "add_sq" +msgstr "add_sq" + +#. §0: `a` +#. §1: `cases a with b` +#. §2: `a = 0` +#. §3: `a = succ b` +#: Game.Levels.LessOrEqual.L08le_total +msgid "" +"This is I think the toughest level yet. Tips: if §0 is a number\n" +"then §1 will split into cases §2 and §3.\n" +"And don't go left or right until your hypotheses guarantee that\n" +"you can prove the resulting goal!\n" +"\n" +"I've left hidden hints; if you need them, retry from the beginning\n" +"and click on \"Show more help!\"" +msgstr "" +"Este é, eu acho, o nível mais difícil até agora. Dicas: se §0 é um número,\n" +"então §1 vai dividir em dois casos, §2 e §3.\n" +"E não vá usando táticas até que suas hipóteses garantam que\n" +"você consegue provar o objetivo resultante!\n" +"\n" +"Deixei dicas escondidas; se você precisar delas, recomece do início\n" +"e clique em \"Mostrar mais ajuda!\"" + +#. §0: `ℕ` +#: Game.Levels.LessOrEqual.L08le_total +msgid "" +"Very well done.\n" +"\n" +"A passing mathematician remarks that with you've just proved that §0 is totally\n" +"ordered.\n" +"\n" +"The final few levels in this world are much easier." +msgstr "" +"Muito bem!\n" +"\n" +"Um matemático que passava por aqui observa que você acabou de provar que §0 é totalmente\n" +"ordenado.\n" +"\n" +"Os últimos níveis deste mundo são bem mais fáceis." + +#. §0: `y` +#. §1: `add_left_eq_self` +#. §2: `add_right_cancel` +#. §3: `` +#. §4: `>_` +#. §5: ``` +#. nth_rewrite 2 [← zero_add y] +#. exact add_right_cancel x 0 y +#. ``` +#: Game.Levels.AdvAddition.L03add_left_eq_self +msgid "" +"Did you use induction on §0?\n" +"Here's a two-line proof of §1 which uses §2.\n" +"If you want to inspect it, you can go into editor mode by clicking §3 in the top right\n" +"and then just cut and paste the proof and move your cursor around it\n" +"to see the hypotheses and goal at any given point\n" +"(although you'll lose your own proof this way). Click §4 to get\n" +"back to command line mode.\n" +"§5" +msgstr "" +"Você usou indução em §0?\n" +"Aqui está uma prova de duas linhas de §1 que usa §2.\n" +"Se quiser inspecioná-la, você pode entrar no modo editor clicando em §3 no canto superior direito\n" +"e depois só copiar e colar a prova e mover o cursor por ela\n" +"para ver as hipóteses e o objetivo em cada ponto\n" +"(embora você perca a sua própria prova assim). Clique em §4 para\n" +"voltar ao modo linha de comando.\n" +"§5" + +#. §0: `a = 0` +#. §1: `x + a = x` +#: Game.Levels.Addition.L05add_right_comm +msgid "" +"You've now seen all the tactics you need to beat the final boss of the game.\n" +"You can begin the journey towards this boss by entering Multiplication World.\n" +"\n" +"Or you can go off the beaten track and learn some new tactics in Implication\n" +"World. These tactics let you prove more facts about addition, such as\n" +"how to deduce §0 from §1.\n" +"\n" +"Click \"Leave World\" and make your choice." +msgstr "" +"Você já viu todas as táticas de que precisa para derrotar o chefão final do jogo.\n" +"Você pode começar a jornada até esse chefão entrando no Mundo da Multiplicação.\n" +"\n" +"Ou pode sair do caminho comum e aprender algumas táticas novas no Mundo da\n" +"Implicação. Essas táticas permitem provar mais fatos sobre a adição, como\n" +"deduzir §0 a partir de §1.\n" +"\n" +"Clique em \"Leave World\" e faça a sua escolha." + +#: Game.Levels.LessOrEqual.L05le_zero +msgid "" +"It's \"intuitively obvious\" that there are no numbers less than zero,\n" +"but to prove it you will need a result which you showed in advanced\n" +"addition world." +msgstr "" +"É \"intuitivamente óbvio\" que não existem números menores que zero,\n" +"mas para provar isso você vai precisar de um resultado que você mostrou no\n" +"Mundo da Adição Avançada." + +#. §0: `exact h` +#: Game.Levels.Implication.L04succ_inj +msgid "" +"And now we've deduced what we wanted to prove: the goal is one of our assumptions.\n" +"Finish the level with §0." +msgstr "" +"E agora deduzimos o que queríamos provar: o objetivo é uma das nossas hipóteses.\n" +"Termine o nível com §0." + +#. §0: `rw [add_zero]` +#: Game.Levels.Tutorial.L07add_succ +msgid "And now §0" +msgstr "E agora §0" + +#. §0: `pow_add a m n` +#. §1: $a^{m+n}=a^ma^n.$ +#: Game.Levels.Power.L06pow_add Game.Levels.Power.L07mul_pow Game.Levels.Power.L08pow_pow +msgid "§0 is a proof that §1" +msgstr "§0 é a prova de que §1" + +#: Game.Levels.LessOrEqual +msgid "≤ World" +msgstr "Mundo do ≤" + +#. §0: ``` +#. rw [mul_comm, mul_one] +#. rfl +#. ``` +#: Game.Levels.Multiplication.L05one_mul Game.Levels.Multiplication.L06two_mul +msgid "" +"Here's my solution:\n" +"§0" +msgstr "" +"Esta é a minha solução:\n" +"§0" + +#: Game.Levels.Algorithm.L07succ_ne_succ +msgid "An algorithm for equality" +msgstr "Um algoritmo para igualdade" + +#: Game.Levels.AdvMultiplication.L05le_mul_right +msgid "le_mul_right" +msgstr "le_mul_right" + +#: Game.Levels.Power +msgid "Power World" +msgstr "Mundo da Potência" + +#. §0: ``` +#. nth_rewrite 2 [← mul_one a] at h +#. exact mul_left_cancel a b 1 ha h +#. ``` +#: Game.Levels.AdvMultiplication.L10mul_right_eq_self +msgid "" +"A two-line proof is\n" +"\n" +"§0\n" +"\n" +"We now have all the tools necessary to set up the basic theory of divisibility of naturals." +msgstr "" +"Uma prova de duas linhas é\n" +"\n" +"§0\n" +"\n" +"Agora temos todas as ferramentas necessárias para montar a teoria básica da divisibilidade dos naturais." + +#: Game.Levels.Multiplication.L06two_mul +msgid "two_mul" +msgstr "two_mul" + +#: Game.Levels.Algorithm.L04add_algo3 +msgid "the simplest approach" +msgstr "a abordagem mais simples" + +#. §0: $P\\implies Q$ +#. §1: $P$ +#. §2: $Q$ +#. §3: `exact` +#. §4: `exact h` +#: Game.Levels.Implication.L01exact +msgid "" +"In this world we'll learn how to prove theorems of the form §0.\n" +"In other words, how to prove theorems of the form \"if §1 is true, then §2 is true.\"\n" +"To do that we need to learn some more tactics.\n" +"\n" +"The §3 tactic can be used to close a goal which is exactly one of\n" +"the hypotheses. It takes the name of the hypothesis as argument: §4." +msgstr "" +"Neste mundo vamos aprender a provar teoremas da forma §0.\n" +"Em outras palavras, como provar teoremas da forma \"se §1 é verdadeiro, então §2 é verdadeiro.\"\n" +"Para isso precisamos aprender mais algumas táticas.\n" +"\n" +"A tática §3 pode ser usada para fechar um objetivo que é exatamente uma\n" +"das hipóteses. Ela recebe o nome da hipótese como argumento: §4." + +#: Game.Levels.Algorithm.L02add_algo1 +msgid "" +"So that's the algorithm: now let's use automation to perform it\n" +"automatically." +msgstr "" +"Esse é o algoritmo: agora vamos usar automação para executá-lo\n" +"automaticamente." + +#. §0: `x + y = 0 → x = 0` +#. §1: `x + y = x → y = 0` +#. §2: `x * y = 1 → x = 1` +#. §3: `x * y = x → y = 1` +#. §4: `x ≠ 0` +#: Game.Levels.AdvMultiplication +msgid "" +"Advanced *Addition* World proved various implications\n" +"involving addition, such as §0 and §1.\n" +"These lemmas were used to prove basic facts about ≤ in ≤ World.\n" +"\n" +"In Advanced Multiplication World we prove analogous\n" +"facts about multiplication, such as §2, and\n" +"§3 (assuming §4 in the latter result). This will prepare\n" +"us for Divisibility World.\n" +"\n" +"Multiplication World is more complex than Addition World. In the same\n" +"way, Advanced Multiplication world is more complex than Advanced Addition\n" +"World. One reason for this is that certain intermediate results are only\n" +"true under the additional hypothesis that one of the variables is non-zero.\n" +"This causes some unexpected extra twists." +msgstr "" +"No Mundo da *Adição* Avançada provamos várias implicações\n" +"envolvendo adição, como §0 e §1.\n" +"Esses lemas foram usados para provar fatos básicos sobre ≤ no Mundo do ≤.\n" +"\n" +"No Mundo da Multiplicação Avançada provamos fatos análogos\n" +"sobre multiplicação, como §2 e\n" +"§3 (supondo §4 neste último resultado). Isso vai nos preparar\n" +"para o Mundo da Divisibilidade.\n" +"\n" +"O Mundo da Multiplicação é mais complexo que o Mundo da Adição. Do mesmo\n" +"jeito, o Mundo da Multiplicação Avançada é mais complexo que o Mundo da Adição\n" +"Avançada. Uma razão para isso é que certos resultados intermediários só\n" +"são verdadeiros sob a hipótese adicional de que uma das variáveis é não nula.\n" +"Isso causa algumas reviravoltas inesperadas." + +#. §0: `simp only [add_left_comm, add_comm]` +#: Game.Levels.Algorithm.L03add_algo2 +msgid "Solve this level in one line with §0" +msgstr "Resolva este nível em uma linha com §0" + +#. §0: `succ_inj` +#. §1: $0$ +#: Game.Levels.Algorithm.L05pred +msgid "" +"Nice! You've proved §0!\n" +"Let's now prove Peano's other axiom, that successors can't be §1." +msgstr "" +"Muito bem! Você provou §0!\n" +"Agora vamos provar o outro axioma de Peano, de que sucessores não podem ser §1." + +#. §0: $a$ +#. §1: $\\operatorname{succ}(a) = a+1$ +#: Game.Levels.Tutorial.L07add_succ Game.Levels.Addition.L01zero_add +#: Game.Levels.Multiplication.L02zero_mul +msgid "For all natural numbers §0, we have §1." +msgstr "Para todo número natural §0, temos §1." + +#: Game.Levels.AdvAddition.L05add_right_eq_zero +msgid "Well done!" +msgstr "Muito bem!" + +#: Game.Levels.Tutorial.L06add_zero2 +msgid "Precision rewriting" +msgstr "Reescrita com precisão" + +#. §0: $a(b+c)=ab+ac$ +#. §1: $(b+c)a=ba+ca$ +#. §2: `mul_add a b c` +#. §3: `a * (b + c) = a * b + a * c` +#: Game.Levels.Multiplication.L07mul_add +msgid "" +"Our next goal is \"left and right distributivity\",\n" +"meaning §0 and §1. Rather than\n" +"these slightly pompous names, the name of the proofs\n" +"in Lean are descriptive. Let's start with\n" +"§2, the proof of §3.\n" +"Note that the left hand side contains a multiplication\n" +"and then an addition." +msgstr "" +"Nosso próximo objetivo é a \"distributividade à esquerda e à direita\",\n" +"ou seja, §0 e §1. Em vez desses\n" +"nomes um tanto pomposos, os nomes das provas\n" +"em Lean são descritivos. Vamos começar com\n" +"§2, a prova de §3.\n" +"Note que o lado esquerdo contém uma multiplicação\n" +"e depois uma adição." + +#. §0: `xyzzy` +#. §1: `sorry` +#. §2: `xyzzy` +#: Game.Levels.Power.L10FLT +msgid "" +"§0 is an ancient magic spell, believed to be the origin of the\n" +"modern word §1. The game won't complain - or notice - if you\n" +"prove anything with §2." +msgstr "" +"§0 é um antigo feitiço mágico, tido como a origem da\n" +"palavra moderna §1. O jogo não vai reclamar - nem perceber - se você\n" +"provar qualquer coisa com §2." + +#. §0: `0 ^ 0 = 0` +#. §1: `0 ^ 0 = 1` +#: Game.Levels.Power.L01zero_pow_zero +msgid "" +"Mathematicians sometimes argue that §0 is also\n" +"a good convention. But it is not a good convention in this\n" +"game; all the later levels come out beautifully with the\n" +"convention that §1." +msgstr "" +"Matemáticos às vezes argumentam que §0 também\n" +"é uma boa convenção. Mas ela não é uma boa convenção neste\n" +"jogo; todos os níveis seguintes ficam lindos com a\n" +"convenção de que §1." + +#. §0: ``` +#. cases h with d hd +#. use d * t +#. rw [hd, add_mul] +#. rfl +#. ``` +#: Game.Levels.AdvMultiplication.L01mul_le_mul_right +msgid "" +"My proof:\n" +"§0" +msgstr "" +"Minha prova:\n" +"§0" + +#: Game.Levels.Multiplication.L06two_mul +msgid "" +"This level is more important than you think; it plays\n" +"a useful role when battling a big boss later on." +msgstr "" +"Este nível é mais importante do que você pensa; ele tem\n" +"um papel útil na batalha contra um grande chefão mais adiante." + +#. §0: `cases h2 with h0 h1` +#: Game.Levels.AdvMultiplication.L06mul_right_eq_one +msgid "" +"Now §0 and deal with the two\n" +"cases separately." +msgstr "" +"Agora faça §0 e trate os dois\n" +"casos separadamente." + +#: Game.Levels.Power.L08pow_pow +msgid "" +"The music dies down. Is that it?\n" +"\n" +"Course it isn't, you can\n" +"clearly see that there are two levels left.\n" +"\n" +"A passing mathematician says that mathematicians don't have a name\n" +"for the structure you just constructed. You feel cheated.\n" +"\n" +"Suddenly the music starts up again. This really is the final boss." +msgstr "" +"A música vai diminuindo. Acabou?\n" +"\n" +"Claro que não, você consegue\n" +"ver claramente que ainda faltam dois níveis.\n" +"\n" +"Um matemático que passava por ali diz que os matemáticos não têm um nome\n" +"para a estrutura que você acabou de construir. Você se sente enganado.\n" +"\n" +"De repente a música recomeça. Este é mesmo o chefão final." + +#. §0: `le_one x` +#. §1: `x ≤ 1` +#. §2: `x = 0` +#. §3: `x = 1` +#: Game.Levels.LessOrEqual.L10le_one Game.Levels.AdvMultiplication.L08mul_eq_zero +msgid "§0 is a proof that if §1 then §2 or §3." +msgstr "§0 é a prova de que se §1 então §2 ou §3." + +#: Game.Levels.Tutorial +msgid "Tutorial World" +msgstr "Mundo Tutorial" + +#. §0: `rw [one_eq_succ_zero]` +#: Game.Levels.Tutorial.L07add_succ +msgid "§0 will do this." +msgstr "§0 dá conta disso." + +#. §0: `x ≤ 0` +#. §1: `x = 0` +#. §2: `≤ 1` +#. §3: `≤ 2` +#: Game.Levels.LessOrEqual.L09succ_le_succ +msgid "" +"We've proved that §0 implies §1. The last two levels\n" +"in this world will prove which numbers are §2 and §3.\n" +"This lemma will be helpful for them." +msgstr "" +"Provamos que §0 implica §1. Os dois últimos níveis\n" +"deste mundo vão provar quais números são §2 e §3.\n" +"Este lema será útil para eles." + +#. §0: `cases «{e}» with a` +#: Game.Levels.LessOrEqual.L08le_total +msgid "You still don't know which way to go, so do §0." +msgstr "Você ainda não sabe para que lado ir, então faça §0." + +#: Game.Levels.AdvMultiplication +msgid "Advanced Multiplication World" +msgstr "Mundo da Multiplicação Avançada" + +#. §0: $2$ +#. §1: $0$ +#: Game.Levels.Tutorial.L03two_eq_ss0 Game.Levels.Tutorial.L04rw_backwards +msgid "§0 is the number after the number after §1." +msgstr "§0 é o número depois do número depois de §1." + +#. §0: `2 + 2 = 4` +#: Game.Levels.Tutorial.L02rw +msgid "You now know enough tactics to prove §0! Let's begin the journey." +msgstr "Agora você já conhece táticas suficientes para provar §0! Vamos começar a jornada." + +#. §0: `succ_mul a b` +#. §1: `succ a * b = a * b + b` +#. §2: `mul_succ` +#. §3: `mul_comm` +#. §4: `mul_comm` +#. §5: `mul_succ` +#: Game.Levels.Multiplication.L03succ_mul +msgid "" +"§0 is the proof that §1.\n" +"\n" +"It could be deduced from §2 and §3, however this argument\n" +"would be circular because the proof of §4 uses §5." +msgstr "" +"§0 é a prova de que §1.\n" +"\n" +"Isso poderia ser deduzido de §2 e §3, porém esse argumento\n" +"seria circular, porque a prova de §4 usa §5." + +#: GameServer.RpcHandlers +msgid "level completed! 🎉" +msgstr "nível completado! 🎉" + +#. §0: `a * b` +#. §1: `rw [mul_comm]` +#. §2: `rw` +#: Game.Levels.Power.L07mul_pow +msgid "" +"The music gets ever more dramatic, as we explore\n" +"the interplay between exponentiation and multiplication.\n" +"\n" +"If you're having trouble exchanging the right §0\n" +"because §1 swaps the wrong multiplication,\n" +"then read the documentation of §2 for tips on how to fix this." +msgstr "" +"A música fica cada vez mais dramática, enquanto exploramos\n" +"a interação entre exponenciação e multiplicação.\n" +"\n" +"Se você estiver tendo dificuldade para trocar o §0 certo\n" +"porque §1 troca a multiplicação errada,\n" +"então leia a documentação de §2 para dicas de como resolver isso." + +#. §0: `le_total x y` +#. §1: `x ≤ y` +#. §2: `y ≤ x` +#: Game.Levels.LessOrEqual.L08le_total +msgid "§0 is a proof that §1 or §2." +msgstr "§0 é uma prova de que §1 ou §2." + +#. §0: `ha : 0 ≠ 0` +#. §1: `tauto` +#: Game.Levels.AdvMultiplication.L03eq_succ_of_ne_zero +msgid "" +"In the \"base case\" we have a hypothesis §0, and you can deduce anything\n" +"from a false statement. The §1 tactic will close this goal." +msgstr "" +"No \"caso base\" temos uma hipótese §0, e você pode deduzir qualquer coisa\n" +"a partir de um enunciado falso. A tática §1 vai fechar esse objetivo." + +#: Game.Levels.Tutorial.L07add_succ +msgid "add_succ" +msgstr "add_succ" + +#: Game.Levels.Power.L03pow_one +msgid "pow_one" +msgstr "pow_one" + +#. §0: `rw [two_eq_succ_one, one_eq_succ_zero]` +#. §1: `rfl` +#: Game.Levels.Tutorial.L03two_eq_ss0 +msgid "" +"Note that you can do §0\n" +"and then §1 to solve this level in two lines." +msgstr "" +"Note que você pode fazer §0\n" +"e depois §1 para resolver este nível em duas linhas." + +#: Game.Levels.AdvAddition.L05add_right_eq_zero +msgid "add_right_eq_zero" +msgstr "add_right_eq_zero" + +#: Game.Levels.Tutorial.L05add_zero +msgid "Adding zero" +msgstr "Somando zero" + +#: Game.Levels.Addition.L03add_comm +msgid "" +"[boss battle music]\n" +"\n" +"Look in your inventory to see the proofs you have available.\n" +"These should be enough." +msgstr "" +"[música de batalha contra o chefão]\n" +"\n" +"Olhe no seu inventário para ver as provas que você tem disponíveis.\n" +"Elas devem ser suficientes." + +#. §0: $a, b$ +#. §1: $c$ +#. §2: $d$ +#. §3: $(a + b) + (c + d) = ((a + c) + d) + b.$ +#: Game.Levels.Algorithm.L02add_algo1 +msgid "" +"If §0, §1 and §2 are numbers, we have\n" +"§3" +msgstr "" +"Se §0, §1 e §2 são números, temos\n" +"§3" + +#. §0: `a ≠ 0` +#. §1: `b ≠ 0` +#. §2: `a * b ≠ 0` +#. §3: `a` +#. §4: `b` +#. §5: `succ` +#. §6: `a * b` +#. §7: `succ` +#. §8: `apply zero_ne_succ` +#: Game.Levels.AdvMultiplication.L07mul_ne_zero +msgid "" +"This level proves that if §0 and §1 then §2. One strategy\n" +"is to write both §3 and §4 as §5 of something, deduce that §6 is\n" +"also §7 of something, and then §8." +msgstr "" +"Este nível prova que se §0 e §1 então §2. Uma estratégia\n" +"é escrever tanto §3 quanto §4 como §5 de alguma coisa, deduzir que §6 também\n" +"é §7 de alguma coisa, e então §8." + +#: Game.Levels.Power.L02zero_pow_succ +msgid "zero_pow_succ" +msgstr "zero_pow_succ" + +#: Game.Levels.LessOrEqual.L07or_symm +msgid "Ready for the boss level of this world?" +msgstr "Pronto para o chefão deste mundo?" + +#. §0: `mul_add a b c` +#. §1: `a * (b + c) = a * b + a * c` +#: Game.Levels.Multiplication.L07mul_add +msgid "" +"Multiplication distributes\n" +"over addition on the left.\n" +"\n" +"§0 is the proof that §1." +msgstr "" +"A multiplicação é distributiva\n" +"sobre a adição à esquerda.\n" +"\n" +"§0 é a prova de que §1." + +#: Game.Levels.Algorithm +msgid "Algorithm World" +msgstr "Mundo do Algoritmo" + +#. §0: `add_succ a b` +#. §1: `a + succ b = succ (a + b)` +#: Game.Levels.Tutorial.L07add_succ +msgid "§0 is the proof of §1." +msgstr "§0 é a prova de §1." + +#: Game.Levels.Power.L10FLT +msgid "" +"Congratulations! You have proved Fermat's Last Theorem!\n" +"\n" +"Either that, or you used magic..." +msgstr "" +"Parabéns! Você provou o Último Teorema de Fermat!\n" +"\n" +"Ou isso, ou você usou magia..." + +#. §0: `mul_comm` +#. §1: `mul_comm a b` +#. §2: `a * b = b * a` +#: Game.Levels.Multiplication.L04mul_comm +msgid "" +"§0 is the proof that multiplication is commutative. More precisely,\n" +"§1 is the proof that §2." +msgstr "" +"§0 é a prova de que a multiplicação é comutativa. Mais precisamente,\n" +"§1 é a prova de que §2." + +#: Game.Levels.Tutorial.L04rw_backwards +msgid "rewriting backwards" +msgstr "reescrevendo de trás pra frente" + +#. §0: `use` +#. §1: `x` +#. §2: `x = 37` +#. §3: `use 37` +#. §4: `a ≤ b` +#. §5: `c` +#. §6: `b = a + c` +#. §7: `a ≤ b` +#. §8: `use` +#. §9: `b - a` +#. §10: `use b - a` +#. §11: `use` +#. §12: `use 37` +#. §13: `use a` +#. §14: `use a * a + 1` +#: Game.Levels.LessOrEqual.L01le_refl +msgid "" +"## Summary\n" +"\n" +"The §0 tactic makes progress with goals which claim something *exists*.\n" +"If the goal claims that some §1 exists with some property, and you know\n" +"that §2 will work, then §3 will make progress.\n" +"\n" +"Because §4 is notation for \\\\\"there exists §5 such that §6\\\\\",\n" +"you can make progress on goals of the form §7 by §8ing the\n" +"number which is morally §9 (i.e. §10)\n" +"\n" +"Any of the following examples is possible assuming the type of the argument passed to the §11 function " +"is accurate:\n" +"\n" +"- §12\n" +"- §13\n" +"- §14" +msgstr "" +"## Resumo\n" +"\n" +"A tática §0 faz progresso em objetivos que afirmam que algo *existe*.\n" +"Se o objetivo afirma que existe algum §1 com alguma propriedade, e você sabe\n" +"que §2 vai funcionar, então §3 faz progresso.\n" +"\n" +"Como §4 é notação para \\\\\"existe §5 tal que §6\\\\\",\n" +"você pode fazer progresso em objetivos da forma §7 aplicando §8 ao\n" +"número que moralmente é §9 (ou seja, §10)\n" +"\n" +"Qualquer um dos exemplos a seguir é possível, desde que o tipo do argumento passado para a função §11 " +"esteja correto:\n" +"\n" +"- §12\n" +"- §13\n" +"- §14" + +#. §0: `x + y = y + x` +#. §1: `add_comm` +#. §2: `add_zero` +#. §3: `zero_add` +#. §4: `add_comm` +#. §5: `x + y = y + x` +#: Game.Levels.Addition.L01zero_add +msgid "" +"This lemma would have been easy if we had known that §0. That theorem\n" +" is called §1 and it is *true*, but unfortunately its proof *uses* both\n" +" §2 and §3!\n" +"\n" +" Let's continue on our journey to §4, the proof of §5." +msgstr "" +"Este lema teria sido fácil se soubéssemos que §0. Esse teorema\n" +" se chama §1 e é *verdadeiro*, mas infelizmente sua prova *usa* tanto\n" +" §2 quanto §3!\n" +"\n" +" Vamos continuar nossa jornada rumo a §4, a prova de que §5." diff --git a/.i18n/uk/Game.json b/.i18n/uk/Game.json index a3db7c9c..6c46fd4f 100644 --- a/.i18n/uk/Game.json +++ b/.i18n/uk/Game.json @@ -73,12 +73,12 @@ "`zero_ne_succ n` is the proof that `0 ≠ succ n`.\n\nIn Lean, `a ≠ b` is *defined to mean* `a = b → False`. Hence\n`zero_ne_succ n` is really a proof of `0 = succ n → False`.\nHere `False` is a generic false statement. This means that\nyou can `apply zero_ne_succ at h` if `h` is a proof of `0 = succ n`.": "`zero_ne_succ n` є доказом того, що `0 ≠ succ n`.\n\nУ Lean `a ≠ b` *визначено означати* `a = b → False`. Отже\n`zero_ne_succ n` насправді є доказом `0 = succ n → False`.\nТут `False` — це загальне хибне твердження. Це означає, що\nви можете `apply zero_ne_succ at h`, якщо `h` є доказом `0 = succ n`.", "`zero_ne_one` is a proof of `0 ≠ 1`.": "`zero_ne_one` є доказом `0 ≠ 1`.", - "`zero_mul x` is the proof that `0 * x = 0`.\n\nNote: `zero_mul` is a `simp` lemma.": - "`zero_mul x` є доказом того, що `0 * x = 0`.\n\nПримітка: `zero_mul` - це `simp` лема.", + "`zero_mul m` is the proof that `0 * m = 0`.\n\nNote: `zero_mul` is a `simp` lemma.": + "`zero_mul m` є доказом того, що `0 * m = 0`.\n\nПримітка: `zero_mul` - це `simp` лема.", "`zero_le x` is a proof that `0 ≤ x`.": "`zero_le x` є доказом того, що `0 ≤ x`.", - "`zero_add x` is the proof of `0 + x = x`.\n\n`zero_add` is a `simp` lemma, because replacing `0 + x` by `x`\nis almost always what you want to do if you're simplifying an expression.": - "`zero_add x` є доказом що`0 + x = x`.\n\n`zero_add` є лемою `simp`, оскільки заміна `0 + x` на `x`\nмайже завжди те, що ви хочете зробити, якщо ви спрощуєте вираз.", + "`zero_add n` is the proof of `0 + n = n`.\n\n`zero_add` is a `simp` lemma, because replacing `0 + n` by `n`\nis almost always what you want to do if you're simplifying an expression.": + "`zero_add n` є доказом що`0 + n = n`.\n\n`zero_add` є лемою `simp`, оскільки заміна `0 + n` на `n`\nмайже завжди те, що ви хочете зробити, якщо ви спрощуєте вираз.", "`xyzzy` is an ancient magic spell, believed to be the origin of the\nmodern word `sorry`. The game won't complain - or notice - if you\nprove anything with `xyzzy`.": "`xyzzy` — стародавнє магічне заклинання, яке, як вважають, походить від\nсучасне слово `sorry`. Гра не поскаржиться - або не помітить - якщо ви\nдоведете будь-що за допомогою `xyzzy`.", "`two_mul m` is the proof that `2 * m = m + m`.": @@ -127,8 +127,8 @@ "`one_mul m` is the proof `1 * m = m`.": "`one_mul m` є доказом `1 * m = m`.", "`one_le_of_ne_zero a` is a proof that `a ≠ 0 → 1 ≤ a`.": "`one_le_of_ne_zero a` це доказ того, що `a ≠ 0 → 1 ≤ a`.", - "`one_eq_succ_zero` is a proof of `1 = succ 0`.\"": - "`one_eq_succ_zero` є доказом `1 = succ 0`.\"", + "`one_eq_succ_zero` is a proof of `1 = succ 0`.": + "`one_eq_succ_zero` є доказом `1 = succ 0`.", "`nth_rewrite 2 [two_eq_succ_one]` is I think quicker than `rw [two_eq_succ_one]`.": "я думаю, `nth_rewrite 2 [two_eq_succ_one]` швидше, ніж `rw [two_eq_succ_one]`.", "`mul_zero m` is the proof that `m * 0 = 0`.": @@ -216,9 +216,9 @@ "`add_left_cancel a b n` це теорема про те, що $n+a=n+b\\implies a=b$.\nВи можете довести її за допомогою індукції по `n` або ви можете вивести це з `add_right_cancel`.", "`add_left_cancel a b n` is the theorem that $n+a=n+b \\implies a=b.$": "`add_left_cancel a b n` це теорема про те, що $n+a=n+b \\implies a=b.$", - "`add_comm x y` is a proof of `x + y = y + x`.": - "`add_comm x y` є доказом `x + y = y + x`.", - "`add_comm b c` is a proof that `b + c = c + b`. But if your goal\nis `a + b + c = a + c + b` then `rw [add_comm b c]` will not\nwork! Because the goal means `(a + b) + c = (a + c) + b` so there\nis no `b + c` term *directly* in the goal.\n\nUse associativity and commutativity to prove `add_right_comm`.\nYou don't need induction. `add_assoc` moves brackets around,\nand `add_comm` moves variables around.\n\nRemember that you can do more targetted rewrites by\nadding explicit variables as inputs to theorems. For example `rw [add_comm b]`\nwill only do rewrites of the form `b + ? = ? + b`, and `rw [add_comm b c]`\nwill only do rewrites of the form `b + c = c + b`.": + "`add_comm a b` is a proof of `a + b = b + a`.": + "`add_comm a b` є доказом `a + b = b + a`.", + "`add_comm b c` is a proof that `b + c = c + b`. But if your goal\nis `a + b + c = a + c + b` then `rw [add_comm b c]` will not\nwork! Because the goal means `(a + b) + c = (a + c) + b` so there\nis no `b + c` term *directly* in the goal.\n\nUse associativity and commutativity to prove `add_right_comm`.\nYou don't need induction. `add_assoc` moves brackets around,\nand `add_comm` moves variables around.\n\nRemember that you can do more targeted rewrites by\nadding explicit variables as inputs to theorems. For example `rw [add_comm b]`\nwill only do rewrites of the form `b + ? = ? + b`, and `rw [add_comm b c]`\nwill only do rewrites of the form `b + c = c + b`.": "`add_comm b c` є доказом того, що `b + c = c + b`. Але якщо ваша мета\nце `a + b + c = a + c + b`, тоді `rw [add_comm b c]` неспрацює!\nТому що мета означає `(a + b) + c = (a + c) + b` так що в меті\n*безпосередньо* немає члена `b + c`.\n\nВикористовуйте асоціативність і комутативність, щоб підтвердити `add_right_comm`.\nВам не потрібна індукція. `add_assoc` пересуває дужки,\nа `add_comm` переміщує змінні.\n\nПам’ятайте, що ви можете робити більш цілеспрямовані перезаписи за допомогою\nдодавання явних змінних як вхідних даних до теорем. Наприклад `rw [add_comm b]`\nвиконуватиме лише перезапис у формі `b + ? = ? + b` і `rw [add_comm b c]`\nвиконуватиме лише перезапис у формі `b + c = c + b`.", "`add_assoc a b c` is a proof\nthat `(a + b) + c = a + (b + c)`. Note that in Lean `(a + b) + c` prints\nas `a + b + c`, because the notation for addition is defined to be left\nassociative.": "`add_assoc a b c` є доказом\nщо `(a + b) + c = a + (b + c)`. Зверніть увагу, що в Lean друкується `(a + b) + c`\nяк `a + b + c`, тому що нотація для додавання визначена ліво-\nасоціативно.", @@ -232,14 +232,14 @@ "`Pow a b` із нотацією `a ^ b` є звичайним\n піднесення натуральних чисел до ступеня. Всередині це так\n визначається за допомогою двох аксіом:\n\n * `pow_zero a : a ^ 0 = 1`\n\n * `pow_succ a b : a ^ succ b = a ^ b * a`\n\nЗокрема, зауважте, що `0 ^ 0 = 1`.", "`Mul a b`, with notation `a * b`, is the usual\n product of natural numbers. Internally it is\n via two axioms:\n\n * `mul_zero a : a * 0 = 0`\n\n * `mul_succ a b : a * succ b = a * b + a`\n\nOther theorems about naturals, such as `zero_mul`,\nare proved by induction from these two basic theorems.": "`Mul a b` із нотацією `a * b` є звичайним\n добуток натуральних чисел. Всередині це зроблено\n через дві аксіоми:\n\n * `mul_zero a : a * 0 = 0`\n\n * `mul_succ a b : a * succ b = a * b + a`\n\nІнші теореми про натуральні числа, такі як `zero_mul`,\nдоводяться індукцією з цих двох основних теорем.", - "`Add a b`, with notation `a + b`, is\nthe usual sum of natural numbers. Internally it is defined\nvia the following two hypotheses:\n\n* `add_zero a : a + 0 = a`\n\n* `add_succ a b : a + succ b = succ (a + b)`\n\nOther theorems about naturals, such as `zero_add a : 0 + a = a`, are proved\nby induction using these two basic theorems.\"": - "`Add a b` із нотацією `a + b` є\nзвичайною сумою натуральних чисел. Внутрішньо це визначається\nчерез такі дві гіпотези:\n\n* `add_zero a : a + 0 = a`\n\n* `add_succ a b : a + succ b = succ (a + b)`\n\nІнші теореми про натуральні числа, такі як `zero_add a : 0 + a = a`, доводяться\nшляхом індукції із використанням цих двох основних теорем».", + "`Add a b`, with notation `a + b`, is\nthe usual sum of natural numbers. Internally it is defined\nvia the following two hypotheses:\n\n* `add_zero a : a + 0 = a`\n\n* `add_succ a b : a + succ b = succ (a + b)`\n\nOther theorems about naturals, such as `zero_add a : 0 + a = a`, are proved\nby induction using these two basic theorems.": + "`Add a b` із нотацією `a + b` є\nзвичайною сумою натуральних чисел. Внутрішньо це визначається\nчерез такі дві гіпотези:\n\n* `add_zero a : a + 0 = a`\n\n* `add_succ a b : a + succ b = succ (a + b)`\n\nІнші теореми про натуральні числа, такі як `zero_add a : 0 + a = a`, доводяться\nшляхом індукції із використанням цих двох основних теорем.", "[final boss music]": "[музика фінального боса]", "[dramatic music]. Now are you ready to face the first boss of the game?": "[драматична музика]. Тепер ви готові зустрітися з першим босом у грі?", "[boss battle music]\n\nLook in your inventory to see the proofs you have available.\nThese should be enough.": "[музика битви із босом]\n\nПодивіться у свій інвентар, щоб побачити доступні докази.\nЦього має бути достатньо.", - "You've now seen all the tactics you need to beat the final boss of the game.\nYou can begin the journey towards this boss by entering Multiplication World.\n\nOr you can go off the beaten track and learn some new tactics in Implication\nWorld. These tactics let you prove more facts about addition, such as\nhow to deduce `a = 0` from `x + a = x`.\n\nClick \"Leave World\" and make your choice.": + "You've now seen all the tactics you need to beat the final boss of the game.\nYou can begin the journey towards this boss by entering Multiplication World.\n\nOr you can go off the beaten track and learn some new tactics in Implication\nWorld. These tactics let you prove more facts about addition, such as\nhow to deduce `a = 0` from `x + a = x`.\n\nClick \"Home\" and make your choice.": "Тепер ви побачили всі тактики, необхідні для перемоги над фінальним босом у грі.\nВи можете розпочати подорож до цього боса, увійшовши у Світ множення.\n\nАбо ви можете зійти з проторених шляхів і вивчити нову тактику в Світі\nімплікацій. Ці тактики дозволяють доводити більше фактів про додавання, наприклад\nяк вивести `a = 0` з `x + a = x`.\n\nНатисніть «Покинути світ» і зробіть свій вибір.", "You want to use `add_right_eq_zero`, which you already\nproved, but you'll have to start with `symm at` your hypothesis.": "Ви хочете використовувати `add_right_eq_zero`, який ви вже\nдовели, але вам доведеться почати з `symm at` вашої гіпотези.", @@ -516,7 +516,7 @@ "Зверніть увагу, що `succ a + «{d}»` означає `(succ a) + «{d}»`. Помістіть курсор\nна будь-якому `succ` у меті чи припущенні, щоб побачити, що саме він з'їдає.", "Nice! You've proved `succ_inj`!\nLet's now prove Peano's other axiom, that successors can't be $0$.": "Гарно! Ви довели `succ_inj`!\nДавайте тепер доведемо іншу аксіому Пеано, що наступники не можуть бути $0$.", - "Nice!\n\nThe next step in the development of order theory is to develop\nthe theory of the interplay between `≤` and multiplication.\nIf you've already done Multiplication World, you're now ready for\nAdvanced Multiplication World. Click on \"Leave World\" to access it.": + "Nice!\n\nThe next step in the development of order theory is to develop\nthe theory of the interplay between `≤` and multiplication.\nIf you've already done Multiplication World, you're now ready for\nAdvanced Multiplication World. Click on \"Home\" to access it.": "Гарно!\n\nНаступним кроком у розвитку теорії порядку є розробка\nтеорія взаємодії між `≤` і множенням.\nЯкщо ви вже працювали зі Світом множення, тепер ви готові\nдо Розширеного світу множення. Натисніть «Залишити світ», щоб отримати до нього доступ.", "Nice!": "Гарно!", "Next turn `1` into `succ 0` with `rw [one_eq_succ_zero]`.": @@ -655,7 +655,7 @@ "Як нам визначити `37 * x`? Як і додавання, нам потрібно дати визначення\nколи $x=0$ і коли $x$ є наступником.\n\nНульовий випадок простий: ми визначаємо `37 * 0` як `0`. Тепер скажіть, що ми знаємо\n`37 * d`. Чим має бути `37 * succ d`? Ну, це $(d+1)$ $37$s,\nтому має бути `37 * d + 37`.\n\nОсь визначення в Lean.\n\n * `mul_zero a : a * 0 = 0`\n * `mul_succ a d : a * succ d = a * d + a`\n\nУ цьому світі ми повинні не лише доводити такі факти про множення, як `a * b = b * a`,\nми також повинні довести факти про те, як множення взаємодіє з додаванням, наприклад `a * (b + c) = a * b + a * c`.\nДавайте почнемо.", "How about this for a proof:\n```\nrepeat rw [add_comm n]\nexact add_right_cancel a b n\n```": "Як щодо цього як доказ:\n```\nrepeat rw [add_comm n]\nexact add_right_cancel a b n\n```", - "How about this for a proof:\n\n```\nrw [add_comm]\nexact add_right_eq_zero b a\n```\n\nThat's the end of Advanced Addition World! You'll need these theorems\nfor the next world, `≤` World. Click on \"Leave World\" to access it.": + "How about this for a proof:\n\n```\nrw [add_comm]\nexact add_right_eq_zero b a\n```\n\nThat's the end of Advanced Addition World! You'll need these theorems\nfor the next world, `≤` World. Click on \"Home\" to access it.": "Як щодо цього доказу:\n\n```\nrw [add_comm]\nexact add_right_eq_zero b a\n```\n\nОсь і кінець Світу розширеного додавання! Вам знадобляться ці теореми\nдля наступного світу, Світу `≤`. Натисніть «Залишити світ», щоб отримати до нього доступ.", "Here's what I was thinking of:\n```\napply mul_left_ne_zero at h\napply one_le_of_ne_zero at h\napply mul_le_mul_right 1 b a at h\nrw [one_mul, mul_comm] at h\nexact h\n```": "Ось про що я думав:\n```\napply mul_left_ne_zero at h\napply one_le_of_ne_zero at h\napply mul_le_mul_right 1 b a at h\nrw [one_mul, mul_comm] at h\nexact h\n```", @@ -669,7 +669,7 @@ "Ось моє рішення:\n```\ninduction c with d hd\nrw [add_zero, mul_zero, add_zero]\nrfl\nrw [add_succ, mul_succ, hd, mul_succ, add_assoc]\nrfl\n```\n\nІндукція по `a` або `b` також буде працювати, але це може зайняти більше часу.", "Here's my proof:\n```\nrw [mul_comm, mul_add]\nrepeat rw [mul_comm c]\nrfl\n```": "Ось мій доказ:\n```\nrw [mul_comm, mul_add]\nrepeat rw [mul_comm c]\nrfl\n```", - "Here's my proof:\n```\nintro h\nrw [add_succ, add_succ, add_zero] at h\nrepeat apply succ_inj at h\napply zero_ne_succ at h\nexact h\n```\n\nEven though Lean is a theorem prover, right now it's pretty clear that we have not\ndeveloped enough material to make it an adequate calculator. In Algorithm\nWorld, a more computer-sciency world, we will develop machinery which makes\nquestions like this much easier, and goals like $20 + 20 ≠ 41$ feasible.\nAlternatively you can do more mathematics in Advanced Addition World, where we prove\nthe lemmas needed to get a working theory of inequalities. Click \"Leave World\" and\ndecide your route.": + "Here's my proof:\n```\nintro h\nrw [add_succ, add_succ, add_zero] at h\nrepeat apply succ_inj at h\napply zero_ne_succ at h\nexact h\n```\n\nEven though Lean is a theorem prover, right now it's pretty clear that we have not\ndeveloped enough material to make it an adequate calculator. In Algorithm\nWorld, a more computer-sciency world, we will develop machinery which makes\nquestions like this much easier, and goals like $20 + 20 ≠ 41$ feasible.\nAlternatively you can do more mathematics in Advanced Addition World, where we prove\nthe lemmas needed to get a working theory of inequalities. Click \"Home\" and\ndecide your route.": "Ось мій доказ:\n```\nintro h\nrw [add_succ, add_succ, add_zero] at h\nrepeat apply succ_inj at h\napply zero_ne_succ at h\nexact h\n```\n\nНезважаючи на те, що Lean є інструментом доказу теорем, наразі цілком зрозуміло, що ми не\nрозробили достатньо матеріалу, щоб зробити його адекватним калькулятором. В Світі\nАлгоритмів, більш комп’ютерно-науковому світі, ми будемо розробляти машинерію, яка зробить\nподібні запитання набагато простішими, а таку мета, як $20 + 20 ≠ 41$, здійсненною.\nКрім того, ви можете робити більше математики в Світі продвинотого додавання, де ми перевіряємо\nлеми, необхідні для отримання робочої теорії нерівностей. Натисніть «Залишити світ» і\nвиріште свій подальшій маршрут.", "Here's my proof:\n```\ncases x with y\nleft\nrfl\nrw [one_eq_succ_zero] at hx ⊢\napply succ_le_succ at hx\napply le_zero at hx\nrw [hx]\nright\nrfl\n```\n\nIf you solved this level then you should be fine with the next level!": "Ось мій доказ:\n```\n\ncases x with y\nleft\nrfl\nrw [one_eq_succ_zero] at hx ⊢\napply succ_le_succ at hx\napply le_zero at hx\nrw [hx]\nright\nrfl\n```\n\nЯкщо ви вирішите цей рівень, то у вас буде все добре з наступним рівнем!", @@ -689,7 +689,7 @@ "Тут ми хочемо розглянути випадки `b = 0` і `b ≠ 0` окремо,\nтому почніть із `cases b with d`.", "Here we begin to\ndevelop an algorithm which, given two naturals `a` and `b`, returns the answer\nto \"does `a = b`?\"\n\nHere is the algorithm. First note that `a` and `b` are numbers, and hence\nare either `0` or successors.\n\n*) If `a` and `b` are both `0`, return \"yes\".\n\n*) If one is `0` and the other is `succ n`, return \"no\".\n\n*) If `a = succ m` and `b = succ n`, then return the answer to \"does `m = n`?\"\n\nOur job now is to *prove* that this algorithm always gives the correct answer. The proof that\n`0 = 0` is `rfl`. The proof that `0 ≠ succ n` is `zero_ne_succ n`, and the proof\nthat `succ m ≠ 0` is `succ_ne_zero m`. The proof that if `h : m = n` then\n`succ m = succ n` is `rw [h]` and then `rfl`. This level is a proof of the one\nremaining job we have to do: if `a ≠ b` then `succ a ≠ succ b`.": "Ось ми і починаємо\nрозробити алгоритм, який, маючи два натуральних числа `a` і `b`, повертає відповідь\nна \"чи `a = b`?\"\n\nОсь алгоритм. Спочатку зауважте, що `a` і `b` є числами, а отже\nвони або `0`, або наступники.\n\n*) Якщо `a` і `b` обидва є `0`, поверніть \"yes\".\n\n*) Якщо один це `0`, а інший це `succ n`, поверніть \"ні\".\n\n*) Якщо `a = succ m` і `b = succ n`, тоді повертається відповідь на питання \"чи `m = n`?\"\n\nЗараз наше завдання - *довести*, що цей алгоритм завжди дає правильну відповідь. Доказ що\n`0 = 0` це `rfl`. Доказом того, що `0 ≠ succ n` є `zero_ne_succ n`, і доказом\nщо `succ m ≠ 0` є `succ_ne_zero m`. Доказ того, що якщо `h : m = n`, то\n`succ m = succ n` — це `rw [h]`, а потім `rfl`. Цей рівень є доказом єдиної\nзалишившийся роботи, яку ми маємо виконати: якщо `a ≠ b`, тоді `succ a ≠ succ b`.", - "Here is an example proof of 2+2=4 showing off various techniques.\n\n```lean\nnth_rewrite 2 [two_eq_succ_one] -- only change the second `2` to `succ 1`.\nrw [add_succ]\nrw [one_eq_succ_zero]\nrw [add_succ, add_zero] -- two rewrites at once\nrw [← three_eq_succ_two] -- change `succ 2` to `3`\nrw [← four_eq_succ_three]\nrfl\n```\n\nOptional extra: you can run this proof yourself. Switch the game into \"Editor mode\" by clicking\non the `` button in the top right. You can now see your proof\nwritten as several lines of code. Move your cursor between lines to see\nthe goal state at any point. Now cut and paste your code elsewhere if you\nwant to save it, and paste the above proof in instead. Move your cursor\naround to investigate. When you've finished, click the `>_` button in the top right to\nmove back into \"Typewriter mode\".\n\nYou have finished tutorial world!\nClick \"Leave World\" to go back to the\noverworld, and select Addition World, where you will learn\nabout the `induction` tactic.": + "Here is an example proof of 2+2=4 showing off various techniques.\n\n```lean\nnth_rewrite 2 [two_eq_succ_one] -- only change the second `2` to `succ 1`.\nrw [add_succ]\nrw [one_eq_succ_zero]\nrw [add_succ, add_zero] -- two rewrites at once\nrw [← three_eq_succ_two] -- change `succ 2` to `3`\nrw [← four_eq_succ_three]\nrfl\n```\n\nOptional extra: you can run this proof yourself. Switch the game into \"Editor mode\" by clicking\non the `` button in the top right. You can now see your proof\nwritten as several lines of code. Move your cursor between lines to see\nthe goal state at any point. Now cut and paste your code elsewhere if you\nwant to save it, and paste the above proof in instead. Move your cursor\naround to investigate. When you've finished, click the `>_` button in the top right to\nmove back into \"Typewriter mode\".\n\nYou have finished tutorial world!\nClick \"Home\" to go back to the\noverworld, and select Addition World, where you will learn\nabout the `induction` tactic.": "Ось приклад доказу 2+2=4 із демонстрацією різних технік.\n\n```lean\nnth_rewrite 2 [two_eq_succ_one] -- змінює лише другий `2` на `succ 1`.\nrw [add_succ]\nrw [one_eq_succ_zero]\nrw [add_succ, add_zero] -- два перезаписи одночасно\nrw [← three_eq_succ_two] -- змінює `succ 2` на `3`\nrw [← four_eq_succ_three]\nrfl\n```\n\nДодатково: ви можете виконати цей доказ самостійно. Переведіть гру в «Режим редактора», клацнувши\nна кнопці `` у верхньому правому куті. Тепер ви можете побачити свій доказ\nнаписаний у вигляді декількох рядків коду. Переміщуйте курсор між рядками, щоб побачити\nцільовий стан у будь-якій точці. Тепер виріжте та вставте свій код в іншому місці, якщо ви\nхочете зберегти його та вставте натомість наведене вище підтвердження. Перемістіть курсор\nнавколо, щоб дослідити. Коли ви закінчите, натисніть кнопку `>_` у верхньому правому куті, щоб\nповернутися назад у «Режим друку».\n\nВи закінчили навчальний світ!\nНатисніть «Залишити світ», щоб повернутися до\nвсесвіту і виберіть Світ додавання, де ви дізнаєтесь\nпро тактику `induction`.", "Having to rearrange variables manually using commutativity and\nassociativity is very tedious. We start by reminding you of this. `add_left_comm`\nis a key component in the first algorithm which we'll explain, but we need\nto prove it manually.\n\nRemember that you can do precision commutativity rewriting\nwith things like `rw [add_comm b c]`. And remember that\n`a + b + c` means `(a + b) + c`.": "Потреба переставляти змінні вручну за допомогою комутативності та\nасоціативність дуже нудна. Ми починаємо з нагадування вам про це. `add_left_comm`\nє ключовим компонентом у першому алгоритмі, як саме ми пояснимо далі, але його нам потрібно\nдовести вручну.\n\nПам’ятайте, що ви можете виконувати точне перезаписування комутативності\nз такими речами, як `rw [add_comm b c]`. І пам'ятайте що\n`a + b + c` означає `(a + b) + c`.", @@ -731,7 +731,7 @@ "Для всіх натуральних чисел $a$ і $b$ маємо\n$(\\operatorname{succ}\\ a) \\times b = a\\times b + b$.", "First execute `rw [h]` to replace the `y` with `x + 7`.": "Спочатку виконайте `rw [h]`, щоб замінити `y` на `x + 7`.", - "Finally use a targetted `add_comm` to switch `b` and `d`": + "Finally use a targeted `add_comm` to switch `b` and `d`": "Нарешті використовуйте націлений `add_comm`, щоб переключити `b` і `d`", "Fermat's Last Theorem": "Остання теорема Ферма", "Every number in Lean is either $0$ or a successor. We know how to add $0$,\nbut we need to figure out how to add successors. Let's say we already know\nthat `37 + d = q`. What should the answer to `37 + succ d` be? Well,\n`succ d` is one bigger than `d`, so `37 + succ d` should be `succ q`,\nthe number one bigger than `q`. More generally `x + succ d` should\nbe `succ (x + d)`. Let's add this as a lemma.\n\n* `add_succ x d : x + succ d = succ (x + d)`\n\nIf you ever see `... + succ ...` in your goal, `rw [add_succ]` is\nnormally a good idea.\n\nLet's now prove that `succ n = n + 1`. Figure out how to get `+ succ` into\nthe picture, and then `rw [add_succ]`. Switch between the `+` (addition) and\n`012` (numerals) tabs under \"Theorems\" on the right to\nsee which proofs you can rewrite.": @@ -799,8 +799,8 @@ "2 + 2 ≠ 5": "2 + 2 ≠ 5", "1 ≠ 0": "1 ≠ 0", "0 ≤ x": "0 ≤ x", - "*Game version: 4.3*\n\n*Recent additions: bug fixes*\n\n## Progress saving\n\nThe game stores your progress in your local browser storage.\nIf you delete it, your progress will be lost!\n\nWarning: In most browsers, deleting cookies will also clear the local storage\n(or \"local site data\"). Make sure to download your game progress first!\n\n## Credits\n\n* **Creators:** Kevin Buzzard, Jon Eugster\n* **Original Lean3-version:** Kevin Buzzard, Mohammad Pedramfar\n* **Game Engine:** Alexander Bentkamp, Jon Eugster, Patrick Massot\n* **Additional levels:** Sian Carey, Ivan Farabella, Archie Browne.\n* **Additional thanks:** All the student beta testers, all the schools\nwho invited Kevin to speak, and all the schoolkids who asked him questions\nabout the material.\n\n## Resources\n\n* The [Lean Zulip chat](https://leanprover.zulipchat.com/) forum\n* [Original Lean3 version](https://www.ma.imperial.ac.uk/~buzzard/xena/natural_number_game/) (no longer maintained)\n\n## Problems?\n\nPlease ask any questions about this game in the\n[Lean Zulip chat](https://leanprover.zulipchat.com/) forum, for example in\nthe stream \"New Members\". The community will happily help. Note that\nthe Lean Zulip chat is a professional research forum.\nPlease use your full real name there, stay on topic, and be nice. If you're\nlooking for somewhere less formal (e.g. you want to post natural number\ngame memes) then head on over to the [Lean Discord](https://discord.gg/WZ9bs9UCvx).\n\nAlternatively, if you experience issues / bugs you can also open github issues:\n\n* For issues with the game engine, please open an\n[issue at the lean4game](https://github.com/leanprover-community/lean4game/issues) repo.\n* For issues about the game's content, please open an\n[issue at the NNG](https://github.com/hhu-adam/NNG4/issues) repo.": - "*Версія гри: 4.3*\n\n*Останні доповнення: виправлення помилок*\n\n## Збереження прогресу\n\nГра зберігає ваш прогрес у локальному сховищі браузера.\nЯкщо ви видалите його, ваш прогрес буде втрачено!\n\nПопередження: у більшості браузерів видалення файлів cookie також очищає локальне сховище\n(або «дані локального сайту»). Обов’язково спершу скачайте свій прогрес гри!\n\n## Подяки\n\n* **Творці:** Кевін Баззард, Джон Югстер\n* **Оригінальна версія Lean3:** Кевін Баззард, Мохаммад Педрамфар\n* **Ігровий рушій:** Олександр Бенткамп, Джон Югстер, Патрік Массо\n* **Додаткові рівні:** Сіан Кері, Іван Фарабелла, Арчі Браун.\n* **Додаткова подяка:** Усім учням-бета-тестерам, усім школам\nякі запросли Кевіна виступити, і всіх школярів, які ставили йому запитання\nпро матеріал.\n\n## Ресурси\n\n* Форум [Lean Zulip chat](https://leanprover.zulipchat.com/).\n* [Оригінальна версія Lean3](https://www.ma.imperial.ac.uk/~buzzard/xena/natural_number_game/) (більше не підтримується)\n\n## Проблеми?\n\nБудь ласка, задавайте будь-які запитання щодо цієї гри на\nфорумі [Zulip чату Lean](https://leanprover.zulipchat.com/), наприклад у\nпотік «New Members». Громада з радістю допоможе. Зауважте, що\nчат Lean Zulip — це професійний дослідницький форум.\nБудь ласка, використовуйте тут своє повне справжнє ім’я, не відривайтесь від теми та будьте чемними. Якщо ви\nшукаєте десь менш формальне (наприклад, ви хочете опублікувати меми гри в натуральні числа),\nто перейдіть до [Lean діскорду](https://discord.gg/WZ9bs9UCvx).\n\nКрім того, якщо у вас виникли проблеми / помилки, ви також можете відкрити проблеми на github:\n\n* Якщо у вас виникли проблеми з ігровим двигуном, відкрийте\n[проблема в репозиторії lean4game](https://github.com/leanprover-community/lean4game/issues).\n* Якщо у вас виникли питання щодо вмісту гри, відкрийте\n[проблема в NNG](https://github.com/hhu-adam/NNG4/issues) репі.", + "*Game version: 4.3*\n\n*Recent additions: bug fixes*\n\n## Progress saving\n\nThe game stores your progress in your local browser storage.\nIf you delete it, your progress will be lost!\n\nWarning: In most browsers, deleting cookies will also clear the local storage\n(or \"local site data\"). Make sure to download your game progress first!\n\n## Credits\n\n* **Creators:** Kevin Buzzard, Jon Eugster\n* **Original Lean3-version:** Kevin Buzzard, Mohammad Pedramfar\n* **Game Engine:** Alexander Bentkamp, Jon Eugster, Patrick Massot\n* **Additional levels:** Sian Carey, Ivan Farabella, Archie Browne.\n* **Additional thanks:** All the student beta testers, all the schools\nwho invited Kevin to speak, and all the schoolkids who asked him questions\nabout the material.\n\n## Resources\n\n* The [Lean Zulip chat](https://leanprover.zulipchat.com/) forum\n* [Original Lean3 version](https://github.com/ImperialCollegeLondon/natural_number_game/) (no longer maintained)\n\n## Problems?\n\nPlease ask any questions about this game in the\n[Lean Zulip chat](https://leanprover.zulipchat.com/) forum, for example in\nthe stream \"New Members\". The community will happily help. Note that\nthe Lean Zulip chat is a professional research forum.\nPlease use your full real name there, stay on topic, and be nice. If you're\nlooking for somewhere less formal (e.g. you want to post natural number\ngame memes) then head on over to the [Lean Discord](https://discord.gg/WZ9bs9UCvx).\n\nAlternatively, if you experience issues / bugs you can also open github issues:\n\n* For issues with the game engine, please open an\n[issue at the lean4game](https://github.com/leanprover-community/lean4game/issues) repo.\n* For issues about the game's content, please open an\n[issue at the NNG](https://github.com/hhu-adam/NNG4/issues) repo.": + "*Версія гри: 4.3*\n\n*Останні доповнення: виправлення помилок*\n\n## Збереження прогресу\n\nГра зберігає ваш прогрес у локальному сховищі браузера.\nЯкщо ви видалите його, ваш прогрес буде втрачено!\n\nПопередження: у більшості браузерів видалення файлів cookie також очищає локальне сховище\n(або «дані локального сайту»). Обов’язково спершу скачайте свій прогрес гри!\n\n## Подяки\n\n* **Творці:** Кевін Баззард, Джон Югстер\n* **Оригінальна версія Lean3:** Кевін Баззард, Мохаммад Педрамфар\n* **Ігровий рушій:** Олександр Бенткамп, Джон Югстер, Патрік Массо\n* **Додаткові рівні:** Сіан Кері, Іван Фарабелла, Арчі Браун.\n* **Додаткова подяка:** Усім учням-бета-тестерам, усім школам\nякі запросли Кевіна виступити, і всіх школярів, які ставили йому запитання\nпро матеріал.\n\n## Ресурси\n\n* Форум [Lean Zulip chat](https://leanprover.zulipchat.com/).\n* [Оригінальна версія Lean3](https://github.com/ImperialCollegeLondon/natural_number_game/) (більше не підтримується)\n\n## Проблеми?\n\nБудь ласка, задавайте будь-які запитання щодо цієї гри на\nфорумі [Zulip чату Lean](https://leanprover.zulipchat.com/), наприклад у\nпотік «New Members». Громада з радістю допоможе. Зауважте, що\nчат Lean Zulip — це професійний дослідницький форум.\nБудь ласка, використовуйте тут своє повне справжнє ім’я, не відривайтесь від теми та будьте чемними. Якщо ви\nшукаєте десь менш формальне (наприклад, ви хочете опублікувати меми гри в натуральні числа),\nто перейдіть до [Lean діскорду](https://discord.gg/WZ9bs9UCvx).\n\nКрім того, якщо у вас виникли проблеми / помилки, ви також можете відкрити проблеми на github:\n\n* Якщо у вас виникли проблеми з ігровим двигуном, відкрийте\n[проблема в репозиторії lean4game](https://github.com/leanprover-community/lean4game/issues).\n* Якщо у вас виникли питання щодо вмісту гри, відкрийте\n[проблема в NNG](https://github.com/hhu-adam/NNG4/issues) репі.", "$x=37\\implies x=37$.": "$x=37\\implies x=37$.", "$x+y=x\\implies y=0$.": "$x+y=x\\implies y=0$.", "$x+1=y+1 \\implies x=y$.": "$x+1=y+1 \\implies x=y$.", @@ -840,7 +840,7 @@ "## Резюме\n\nЯкщо `n` є числом, тоді `cases n with d` розділять мету на дві,\nодна із `n = 0`, а інша з `n = succ d`.\n\nЯкщо `h` є доказом (наприклад, гіпотезою), то `cases h with...` розіб'є\nдокази на частини, які будуть використовуватися для доказу.\n\n## Приклад\n\nЯкщо `n : ℕ` є числом, тоді `cases n with d` розділять мету на дві мети,\nодна із `n`, заміненим на 0, а інша із `n`, заміненим на `succ d`. Це\nвідповідає математичній ідеї, що кожне натуральне число дорівнює або `0`\nабо наступнику.\n\n## Приклад\n\nЯкщо `h : P ∨ Q` є гіпотезою, то `cases h with hp hq` перетворять одну мету\nна дві мети, одна з гіпотезою `hp : P`, а інша з a\nгіпотезою `hq : Q`.\n\n## Приклад\n\nЯкщо `h : False` є гіпотезою, то `cases h` перетворять одну мету на відсутність мети,\nтому що немає способів зробити доказ `False`! І якщо у вас не залишилося мети,\nви закінчили рівень.\n\n## Приклад\n\nЯкщо `h : a ≤ b` є гіпотезою, то `cases h with c hc` створять нове число `c`\nі доказ `hc : b = a + c`. Це тому, що *визначення* `a ≤ b` таке\n`∃ c, b = a + c`.", "## Summary\n\nIf `n : ℕ` is an object, and the goal mentions `n`, then `induction n with d hd`\nattempts to prove the goal by induction on `n`, with the inductive\nvariable in the successor case being `d`, and the inductive hypothesis being `hd`.\n\n### Example:\nIf the goal is\n```\n0 + n = n\n```\n\nthen\n\n`induction n with d hd`\n\nwill turn it into two goals. The first is `0 + 0 = 0`;\nthe second has an assumption `hd : 0 + d = d` and goal\n`0 + succ d = succ d`.\n\nNote that you must prove the first\ngoal before you can access the second one.": "## Резюме\n\nЯкщо `n : ℕ` є об'єктом, а мета згадує `n`, тоді `induction n with d hd`\nспробує довести мету індукцією по `n`, з індуктивною\nзмінною у випадку наступника із іменем `d`, та індуктивною гіпотезою — `hd`.\n\n### Приклад:\nЯкщо є мета\n```\n0 + n = n\n```\n\nтоді\n\n`induction n with d hd`\n\nперетворить твердження на дві мети. Перша: `0 + 0 = 0`;\nдруга має припущення `hd : 0 + d = d` і мету\n`0 + succ d = succ d`.\n\nЗверніть увагу, що ви повинні спочатку довести першу\nмету, перед тим як ви зможете отримати доступ до другої.", - "## Summary\n\nIf `h` is a proof of an equality `X = Y`, then `rw [h]` will change\nall `X`s in the goal to `Y`s. It's the way to \\\"substitute in\\\".\n\n## Variants\n\n* `rw [← h]` (changes `Y`s to `X`s; get the back arrow by typing `\\left ` or `\\l`.)\n\n* `rw [h1, h2]` (a sequence of rewrites)\n\n* `rw [h] at h2` (changes `X`s to `Y`s in hypothesis `h2`)\n\n* `rw [h] at h1 h2 ⊢` (changes `X`s to `Y`s in two hypotheses and the goal;\nget the `⊢` symbol with `\\|-`.)\n\n* `repeat rw [add_zero]` will keep changing `? + 0` to `?`\nuntil there are no more matches for `? + 0`.\n\n* `nth_rewrite 2 [h]` will change only the second `X` in the goal to `Y`.\n\n### Example:\n\nIf you have the assumption `h : x = y + y` and your goal is\n```\nsucc (x + 0) = succ (y + y)\n```\n\nthen\n\n`rw [add_zero]`\n\nwill change the goal into `succ x = succ (y + y)`, and then\n\n`rw [h]`\n\nwill change the goal into `succ (y + y) = succ (y + y)`, which\ncan be solved with `rfl`.\n\n### Example:\n\nYou can use `rw` to change a hypothesis as well.\nFor example, if you have two hypotheses\n```\nh1 : x = y + 3\nh2 : 2 * y = x\n```\nthen `rw [h1] at h2` will turn `h2` into `h2 : 2 * y = y + 3`.\n\n## Common errors\n\n* You need the square brackets. `rw h` is never correct.\n\n* If `h` is not a *proof* of an *equality* (a statement of the form `A = B`),\nfor example if `h` is a function or an implication,\nthen `rw` is not the tactic you want to use. For example,\n`rw [P = Q]` is never correct: `P = Q` is the theorem *statement*,\nnot the proof. If `h : P = Q` is the proof, then `rw [h]` will work.\n\n## Details\n\nThe `rw` tactic is a way to do \\\"substituting in\\\". There\nare two distinct situations where you can use this tactic.\n\n1) Basic usage: if `h : A = B` is an assumption or\nthe proof of a theorem, and if the goal contains one or more `A`s, then `rw [h]`\nwill change them all to `B`s. The tactic will error\nif there are no `A`s in the goal.\n\n2) Advanced usage: Assumptions coming from theorem proofs\noften have missing pieces. For example `add_zero`\nis a proof that `? + 0 = ?` because `add_zero` really is a function,\nand `?` is the input. In this situation `rw` will look through the goal\nfor any subterm of the form `x + 0`, and the moment it\nfinds one it fixes `?` to be `x` then changes all `x + 0`s to `x`s.\n\nExercise: think about why `rw [add_zero]` changes the term\n`(0 + 0) + (x + 0) + (0 + 0) + (x + 0)` to\n`0 + (x + 0) + 0 + (x + 0)`\n\nIf you can't remember the name of the proof of an equality, look it up in\nthe list of lemmas on the right.\n\n## Targetted usage\n\nIf your goal is `b + c + a = b + (a + c)` and you want to rewrite `a + c`\nto `c + a`, then `rw [add_comm]` will not work because Lean finds another\naddition first and swaps those inputs instead. Use `rw [add_comm a c]` to\nguarantee that Lean rewrites `a + c` to `c + a`. This works because\n`add_comm` is a proof that `?1 + ?2 = ?2 + ?1`, `add_comm a` is a proof\nthat `a + ? = ? + a`, and `add_comm a c` is a proof that `a + c = c + a`.\n\nIf `h : X = Y` then `rw [h]` will turn all `X`s into `Y`s.\nIf you only want to change the 37th occurrence of `X`\nto `Y` then do `nth_rewrite 37 [h]`.": + "## Summary\n\nIf `h` is a proof of an equality `X = Y`, then `rw [h]` will change\nall `X`s in the goal to `Y`s. It's the way to \\\"substitute in\\\".\n\n## Variants\n\n* `rw [← h]` (changes `Y`s to `X`s; get the back arrow by typing `\\left ` or `\\l`.)\n\n* `rw [h1, h2]` (a sequence of rewrites)\n\n* `rw [h] at h2` (changes `X`s to `Y`s in hypothesis `h2`)\n\n* `rw [h] at h1 h2 ⊢` (changes `X`s to `Y`s in two hypotheses and the goal;\nget the `⊢` symbol with `\\|-`.)\n\n* `repeat rw [add_zero]` will keep changing `? + 0` to `?`\nuntil there are no more matches for `? + 0`.\n\n* `nth_rewrite 2 [h]` will change only the second `X` in the goal to `Y`.\n\n### Example:\n\nIf you have the assumption `h : x = y + y` and your goal is\n```\nsucc (x + 0) = succ (y + y)\n```\n\nthen\n\n`rw [add_zero]`\n\nwill change the goal into `succ x = succ (y + y)`, and then\n\n`rw [h]`\n\nwill change the goal into `succ (y + y) = succ (y + y)`, which\ncan be solved with `rfl`.\n\n### Example:\n\nYou can use `rw` to change a hypothesis as well.\nFor example, if you have two hypotheses\n```\nh1 : x = y + 3\nh2 : 2 * y = x\n```\nthen `rw [h1] at h2` will turn `h2` into `h2 : 2 * y = y + 3`.\n\n## Common errors\n\n* You need the square brackets. `rw h` is never correct.\n\n* If `h` is not a *proof* of an *equality* (a statement of the form `A = B`),\nfor example if `h` is a function or an implication,\nthen `rw` is not the tactic you want to use. For example,\n`rw [P = Q]` is never correct: `P = Q` is the theorem *statement*,\nnot the proof. If `h : P = Q` is the proof, then `rw [h]` will work.\n\n## Details\n\nThe `rw` tactic is a way to do \\\"substituting in\\\". There\nare two distinct situations where you can use this tactic.\n\n1) Basic usage: if `h : A = B` is an assumption or\nthe proof of a theorem, and if the goal contains one or more `A`s, then `rw [h]`\nwill change them all to `B`s. The tactic will error\nif there are no `A`s in the goal.\n\n2) Advanced usage: Assumptions coming from theorem proofs\noften have missing pieces. For example `add_zero`\nis a proof that `? + 0 = ?` because `add_zero` really is a function,\nand `?` is the input. In this situation `rw` will look through the goal\nfor any subterm of the form `x + 0`, and the moment it\nfinds one it fixes `?` to be `x` then changes all `x + 0`s to `x`s.\n\nExercise: think about why `rw [add_zero]` changes the term\n`(0 + 0) + (x + 0) + (0 + 0) + (x + 0)` to\n`0 + (x + 0) + 0 + (x + 0)`\n\nIf you can't remember the name of the proof of an equality, look it up in\nthe list of lemmas on the right.\n\n## Targeted usage\n\nIf your goal is `b + c + a = b + (a + c)` and you want to rewrite `a + c`\nto `c + a`, then `rw [add_comm]` will not work because Lean finds another\naddition first and swaps those inputs instead. Use `rw [add_comm a c]` to\nguarantee that Lean rewrites `a + c` to `c + a`. This works because\n`add_comm` is a proof that `?1 + ?2 = ?2 + ?1`, `add_comm a` is a proof\nthat `a + ? = ? + a`, and `add_comm a c` is a proof that `a + c = c + a`.\n\nIf `h : X = Y` then `rw [h]` will turn all `X`s into `Y`s.\nIf you only want to change the 37th occurrence of `X`\nto `Y` then do `nth_rewrite 37 [h]`.": "## Резюме\n\nЯкщо `h` є доказом рівності `X = Y`, то `rw [h]` зміниться\nвсі `X` у меті на `Y`. Це спосіб \\\"заміни всередині\\\".\n\n## Варіанти\n\n* `rw [← h]` (змінює `Y` на `X`; щоб отримати стрілку назад, ввівши `\\left ` або `\\l`.)\n\n* `rw [h1, h2]` (послідовність перезаписів)\n\n* `rw [h] at h2` (змінює `X` на `Y` в гіпотезі `h2`)\n\n* `rw [h] at h1 h2 ⊢` (змінює `X` на `Y` у двох гіпотезах і меті;\nотримайте символ `⊢` за допомогою `\\|-`.)\n\n* `repeat rw [add_zero]` постійно змінюватиметься `? + 0` до `?`\nпоки не буде більше співпадінь для `? + 0`.\n\n* `nth_rewrite 2 [h]` змінить лише другий `X` у меті на `Y`.\n\n### Приклад:\n\nЯкщо у вас є припущення `h : x = y + y` і ваша мета\n```\nsucc (x + 0) = succ (y + y)\n```\n\nтоді\n\n`rw [add_zero]`\n\nзмінить мету на `succ x = succ (y + y)`, а потім\n\n`rw [h]`\n\nзмінить мету на `succ (y + y) = succ (y + y)`, що\nможна вирішити за допомогою `rfl`.\n\n### Приклад:\n\nВи також можете використовувати `rw`, щоб змінити і гіпотезу також.\nНаприклад, якщо у вас є дві гіпотези\n```\nh1 : x = y + 3\nh2 : 2 * y = x\n```\nтоді `rw [h1] at h2` перетворить `h2` на `h2 : 2 * y = y + 3`.\n\n## Типові помилки\n\n* Вам потрібні квадратні дужки. `rw h` ніколи не буде правильним записом.\n\n* Якщо `h` не є *доказом* *рівності* (твердження у формі `A = B`),\nнаприклад, якщо `h` є функцією або імплікацією,\nтоді `rw` - це не та тактика, яку вам потрібно використовувати. Наприклад,\n`rw [P = Q]` ніколи не буде правильним записом: `P = Q` - *твердження* теореми,\nне доказ. Якщо `h : P = Q` є доказом, то `rw [h]` буде працювати.\n\n## Подробиці\n\nТактика `rw` - це спосіб зробити \\\"заміну всередині\\\". там\nє дві різні ситуації, коли ви можете використовувати цю тактику.\n\n1) Базове використання: якщо `h : A = B` є припущенням або\nдоказом теореми, а якщо ціль містить одну або більше літер `A`, тоді rw [h]\nзмінить їх усіх на `B`. Тактика дасть помилку\nякщо в меті відсутнє`A`.\n\n2) Розширене використання: припущення, що випливають із доказів теорем\nчасто мають відсутні частини. Наприклад `add_zero`\nє доказом того, що `? + 0 = ?`, оскільки `add_zero` насправді є функцією,\nі `?` є вхідним параметром. У цій ситуації `rw` буде дивитися скрізь мету\nу пошуках будь-якого підтерму виду `x + 0`, і у момент коли\nзнаходить один, вона виправляє `?` на `x`, а потім змінює всі `x + 0` на `x`.\n\nВправа: подумайте, чому `rw [add_zero]` змінює терм\n`(0 + 0) + (x + 0) + (0 + 0) + (x + 0)` на\n`0 + (x + 0) + 0 + (x + 0)`\n\nЯкщо ви не пам’ятаєте назву доказу рівності, знайдіть його в\nсписку лем праворуч.\n\n## Цільове використання\n\nЯкщо вашою метою є `b + c + a = b + (a + c)`, і ви хочете переписати `a + c`\nна `c + a`, тоді `rw [add_comm]` не працюватиме, оскільки Lean знаходить спочатку інше\nдодавання та замінює ці вхідні дані замість бажаного. Використовуйте `rw [add_comm a c]` для\nгарантій, що Lean переписує `a + c` на `c + a`. Це працює, тому що\n`add_comm` є доказом того, що `?1 + ?2 = ?2 + ?1`, `add_comm a` є доказом\nщо `a + ? = ? + a`, а `add_comm a c` є доказом того, що `a + c = c + a`.\n\nЯкщо `h : X = Y`, то `rw [h]` перетворить усі `X` на `Y`.\nЯкщо ви хочете змінити лише 37-е входження `X`\nна `Y`, тоді виконайте `nth_rewrite 37 [h]`.", "## Summary\n\nIf `h : X = Y` and there are several `X`s in the goal, then\n`nth_rewrite 3 [h]` will just change the third `X` to a `Y`.\n\n## Example\n\nIf the goal is `2 + 2 = 4` then `nth_rewrite 2 [two_eq_succ_one]`\nwill change the goal to `2 + succ 1 = 4`. In contrast, `rw [two_eq_succ_one]`\nwill change the goal to `succ 1 + succ 1 = 4`.": "## Резюме\n\nЯкщо `h : X = Y` і є кілька `X` у меті, тоді\n`nth_rewrite 3 [h]` просто змінить третій `X` на `Y`.\n\n## Приклад\n\nЯкщо ціль `2 + 2 = 4`, тоді `nth_rewrite 2 [two_eq_succ_one]`\nзмінить мету на `2 + succ 1 = 4`. На відміну від цього, `rw [two_eq_succ_one]`\nзмінить мету на `succ 1 + succ 1 = 4`.", diff --git a/.i18n/uk/Game.po b/.i18n/uk/Game.po index c7f3e66c..d396bfe5 100644 --- a/.i18n/uk/Game.po +++ b/.i18n/uk/Game.po @@ -269,7 +269,7 @@ msgid "" "If you can't remember the name of the proof of an equality, look it up in\n" "the list of lemmas on the right.\n" "\n" -"## Targetted usage\n" +"## Targeted usage\n" "\n" "If your goal is `b + c + a = b + (a + c)` and you want to rewrite `a + c`\n" "to `c + a`, then `rw [add_comm]` will not work because Lean finds another\n" @@ -549,8 +549,8 @@ msgstr "" "ніколи просочуйтеся в гру натуральних чисел.*" #: Game.Levels.Tutorial.L03two_eq_ss0 -msgid "`one_eq_succ_zero` is a proof of `1 = succ 0`.\"" -msgstr "`one_eq_succ_zero` є доказом `1 = succ 0`.\"" +msgid "`one_eq_succ_zero` is a proof of `1 = succ 0`." +msgstr "`one_eq_succ_zero` є доказом `1 = succ 0`." #: Game.Levels.Tutorial.L03two_eq_ss0 msgid "`two_eq_succ_one` is a proof of `2 = succ 1`." @@ -702,7 +702,7 @@ msgid "" "* `add_succ a b : a + succ b = succ (a + b)`\n" "\n" "Other theorems about naturals, such as `zero_add a : 0 + a = a`, are proved\n" -"by induction using these two basic theorems.\"" +"by induction using these two basic theorems." msgstr "" "`Add a b` із нотацією `a + b` є\n" "звичайною сумою натуральних чисел. Внутрішньо це визначається\n" @@ -714,7 +714,7 @@ msgstr "" "\n" "Інші теореми про натуральні числа, такі як `zero_add a : 0 + a = a`, " "доводяться\n" -"шляхом індукції із використанням цих двох основних теорем»." +"шляхом індукції із використанням цих двох основних теорем." #: Game.Levels.Tutorial.L05add_zero msgid "" @@ -1032,7 +1032,7 @@ msgid "" "move back into \"Typewriter mode\".\n" "\n" "You have finished tutorial world!\n" -"Click \"Leave World\" to go back to the\n" +"Click \"Home\" to go back to the\n" "overworld, and select Addition World, where you will learn\n" "about the `induction` tactic." msgstr "" @@ -1155,14 +1155,14 @@ msgstr "" #: Game.Levels.Addition.L01zero_add msgid "" -"`zero_add x` is the proof of `0 + x = x`.\n" +"`zero_add n` is the proof of `0 + n = n`.\n" "\n" -"`zero_add` is a `simp` lemma, because replacing `0 + x` by `x`\n" +"`zero_add` is a `simp` lemma, because replacing `0 + n` by `n`\n" "is almost always what you want to do if you're simplifying an expression." msgstr "" -"`zero_add x` є доказом що`0 + x = x`.\n" +"`zero_add n` є доказом що`0 + n = n`.\n" "\n" -"`zero_add` є лемою `simp`, оскільки заміна `0 + x` на `x`\n" +"`zero_add` є лемою `simp`, оскільки заміна `0 + n` на `n`\n" "майже завжди те, що ви хочете зробити, якщо ви спрощуєте вираз." #: Game.Levels.Addition.L01zero_add @@ -1367,8 +1367,8 @@ msgstr "" "Цього має бути достатньо." #: Game.Levels.Addition.L03add_comm -msgid "`add_comm x y` is a proof of `x + y = y + x`." -msgstr "`add_comm x y` є доказом `x + y = y + x`." +msgid "`add_comm a b` is a proof of `a + b = b + a`." +msgstr "`add_comm a b` є доказом `a + b = b + a`." #: Game.Levels.Addition.L03add_comm msgid "" @@ -1476,7 +1476,7 @@ msgid "" "You don't need induction. `add_assoc` moves brackets around,\n" "and `add_comm` moves variables around.\n" "\n" -"Remember that you can do more targetted rewrites by\n" +"Remember that you can do more targeted rewrites by\n" "adding explicit variables as inputs to theorems. For example `rw [add_comm " "b]`\n" "will only do rewrites of the form `b + ? = ? + b`, and `rw [add_comm b c]`\n" @@ -1528,7 +1528,7 @@ msgid "" "World. These tactics let you prove more facts about addition, such as\n" "how to deduce `a = 0` from `x + a = x`.\n" "\n" -"Click \"Leave World\" and make your choice." +"Click \"Home\" and make your choice." msgstr "" "Тепер ви побачили всі тактики, необхідні для перемоги над фінальним босом у " "грі.\n" @@ -1656,11 +1656,11 @@ msgstr "" #: Game.Levels.Multiplication.L02zero_mul msgid "" -"`zero_mul x` is the proof that `0 * x = 0`.\n" +"`zero_mul m` is the proof that `0 * m = 0`.\n" "\n" "Note: `zero_mul` is a `simp` lemma." msgstr "" -"`zero_mul x` є доказом того, що `0 * x = 0`.\n" +"`zero_mul m` є доказом того, що `0 * m = 0`.\n" "\n" "Примітка: `zero_mul` - це `simp` лема." @@ -3271,8 +3271,8 @@ msgid "" "questions like this much easier, and goals like $20 + 20 ≠ 41$ feasible.\n" "Alternatively you can do more mathematics in Advanced Addition World, where " "we prove\n" -"the lemmas needed to get a working theory of inequalities. Click \"Leave " -"World\" and\n" +"the lemmas needed to get a working theory of inequalities. Click \"Home\" " +"and\n" "decide your route." msgstr "" "Ось мій доказ:\n" @@ -3417,7 +3417,7 @@ msgstr "" "боку." #: Game.Levels.Algorithm.L02add_algo1 -msgid "Finally use a targetted `add_comm` to switch `b` and `d`" +msgid "Finally use a targeted `add_comm` to switch `b` and `d`" msgstr "Нарешті використовуйте націлений `add_comm`, щоб переключити `b` і `d`" #: Game.Levels.Algorithm.L02add_algo1 @@ -4366,7 +4366,7 @@ msgid "" "```\n" "\n" "That's the end of Advanced Addition World! You'll need these theorems\n" -"for the next world, `≤` World. Click on \"Leave World\" to access it." +"for the next world, `≤` World. Click on \"Home\" to access it." msgstr "" "Як щодо цього доказу:\n" "\n" @@ -5060,7 +5060,7 @@ msgid "" "The next step in the development of order theory is to develop\n" "the theory of the interplay between `≤` and multiplication.\n" "If you've already done Multiplication World, you're now ready for\n" -"Advanced Multiplication World. Click on \"Leave World\" to access it." +"Advanced Multiplication World. Click on \"Home\" to access it." msgstr "" "Гарно!\n" "\n" diff --git a/.i18n/zh/Game.json b/.i18n/zh/Game.json index aa08f8a5..dba45d72 100644 --- a/.i18n/zh/Game.json +++ b/.i18n/zh/Game.json @@ -71,11 +71,11 @@ "`zero_ne_succ n` is the proof that `0 ≠ succ n`.\n\nIn Lean, `a ≠ b` is *defined to mean* `a = b → False`. Hence\n`zero_ne_succ n` is really a proof of `0 = succ n → False`.\nHere `False` is a generic false statement. This means that\nyou can `apply zero_ne_succ at h` if `h` is a proof of `0 = succ n`.": "`zero_ne_succ n` 是 `0 ≠ succ n` 的证明。\n\n在 Lean 中,`a ≠ b` *被定义为* `a = b → False`。\n因此,`zero_ne_succ n` 实际上是 `0 = succ n → False` 的证明。\n这里的 `False` 是一个通用的假命题。这意味着如果 `h` 是 `0 = succ n` 的证明,你可以 `apply zero_ne_succ at h`。", "`zero_ne_one` is a proof of `0 ≠ 1`.": "`zero_ne_one` 是 `0 ≠ 1` 的证明。", - "`zero_mul x` is the proof that `0 * x = 0`.\n\nNote: `zero_mul` is a `simp` lemma.": - "`zero_mul x` 是 `0 * x = 0` 的证明。\n\n注意:`zero_mul` 是一个 `simp` 引理。", + "`zero_mul m` is the proof that `0 * m = 0`.\n\nNote: `zero_mul` is a `simp` lemma.": + "`zero_mul m` 是 `0 * m = 0` 的证明。\n\n注意:`zero_mul` 是一个 `simp` 引理。", "`zero_le x` is a proof that `0 ≤ x`.": "`zero_le x` 是 `0 ≤ x` 的证明。", - "`zero_add x` is the proof of `0 + x = x`.\n\n`zero_add` is a `simp` lemma, because replacing `0 + x` by `x`\nis almost always what you want to do if you're simplifying an expression.": - "`zero_add x` 是 `0 + x = x` 的证明。\n\n`zero_add` 是一个有 `simp` 标记的引理,因为如果你正在简化一个表达式,几乎总是想要将 `0 + x` 替换为 `x`。", + "`zero_add n` is the proof of `0 + n = n`.\n\n`zero_add` is a `simp` lemma, because replacing `0 + n` by `n`\nis almost always what you want to do if you're simplifying an expression.": + "`zero_add n` 是 `0 + n = n` 的证明。\n\n`zero_add` 是一个有 `simp` 标记的引理,因为如果你正在简化一个表达式,几乎总是想要将 `0 + n` 替换为 `n`。", "`xyzzy` is an ancient magic spell, believed to be the origin of the\nmodern word `sorry`. The game won't complain - or notice - if you\nprove anything with `xyzzy`.": "`xyzzy` 是一个古老的魔法咒语,被认为是现代词汇 `sorry` 的起源。游戏不会发现——或者注意到你用 `xyzzy` 证明任何东西。", "`two_mul m` is the proof that `2 * m = m + m`.": @@ -119,7 +119,7 @@ "`one_mul m` is the proof `1 * m = m`.": "`one_mul m` 是证明 `1 * m = m`。", "`one_le_of_ne_zero a` is a proof that `a ≠ 0 → 1 ≤ a`.": "`one_le_of_ne_zero a` 是 `a≠0 → 1≤a` 的证明。", - "`one_eq_succ_zero` is a proof of `1 = succ 0`.\"": + "`one_eq_succ_zero` is a proof of `1 = succ 0`.": "`one_eq_succ_zero` 是 `1 = succ 0`的证明。", "`nth_rewrite 2 [two_eq_succ_one]` is I think quicker than `rw [two_eq_succ_one]`.": "我认为 `nth_rewrite 2 [two_eq_succ_one]` 比 `rw [two_eq_succ_one]` 更快。", @@ -207,9 +207,9 @@ "`add_left_cancel a b n` 是定理 $n+a=n+b\\implies a=b$。你可以通过对 `n` 进行归纳来证明它,或者你可以从 `add_right_cancel` 推导出它。", "`add_left_cancel a b n` is the theorem that $n+a=n+b \\implies a=b.$": "`add_left_cancel a b n` 是 $n+a=n+b \\implies a=b$ 的定理名字。", - "`add_comm x y` is a proof of `x + y = y + x`.": - "`add_comm x y` 是 `x + y = y + x` 的证明。", - "`add_comm b c` is a proof that `b + c = c + b`. But if your goal\nis `a + b + c = a + c + b` then `rw [add_comm b c]` will not\nwork! Because the goal means `(a + b) + c = (a + c) + b` so there\nis no `b + c` term *directly* in the goal.\n\nUse associativity and commutativity to prove `add_right_comm`.\nYou don't need induction. `add_assoc` moves brackets around,\nand `add_comm` moves variables around.\n\nRemember that you can do more targetted rewrites by\nadding explicit variables as inputs to theorems. For example `rw [add_comm b]`\nwill only do rewrites of the form `b + ? = ? + b`, and `rw [add_comm b c]`\nwill only do rewrites of the form `b + c = c + b`.": + "`add_comm a b` is a proof of `a + b = b + a`.": + "`add_comm a b` 是 `a + b = b + a` 的证明。", + "`add_comm b c` is a proof that `b + c = c + b`. But if your goal\nis `a + b + c = a + c + b` then `rw [add_comm b c]` will not\nwork! Because the goal means `(a + b) + c = (a + c) + b` so there\nis no `b + c` term *directly* in the goal.\n\nUse associativity and commutativity to prove `add_right_comm`.\nYou don't need induction. `add_assoc` moves brackets around,\nand `add_comm` moves variables around.\n\nRemember that you can do more targeted rewrites by\nadding explicit variables as inputs to theorems. For example `rw [add_comm b]`\nwill only do rewrites of the form `b + ? = ? + b`, and `rw [add_comm b c]`\nwill only do rewrites of the form `b + c = c + b`.": "`add_comm b c` 是一个 `b + c = c + b` 的证明。但如果您的目标是 `a + b + c = a + c + b`,那么 `rw [add_comm b c]` 将不起作用!因为目标是 `(a + b) + c = (a + c) + b`,所以目标中*直接*没有 `b + c` 项。\n\n使用结合律和交换律来证明 `add_right_comm`。您不需要使用归纳法。`add_assoc` 移动括号,`add_comm` 移动变量。\n\n请记住,您可以通过将显式变量添加为定理的输入来进行更有针对性的重写。\n例如,`rw [add_comm b]` 只会重写形如 `b + ? = ? + b` 的形式,而 `rw [add_comm b c]` 只会重写形如 `b + c = c + b` 的形式。", "`add_assoc a b c` is a proof\nthat `(a + b) + c = a + (b + c)`. Note that in Lean `(a + b) + c` prints\nas `a + b + c`, because the notation for addition is defined to be left\nassociative.": "`add_assoc a b c` 是一个 `(a + b) + c = a + (b + c)` 的证明。\n请注意,在 Lean `(a + b) + c` 中显示\n为 `a + b + c`,因为加法符号被定义为左\n结合的。", @@ -223,14 +223,14 @@ "`Pow a b`,其符号表示为 `a ^ b`,是自然数的常规指数运算。在内部,它是通过两个公理定义的:\n\n* `pow_zero a : a ^ 0 = 1`\n\n* `pow_succ a b : a ^ succ b = a ^ b * a`\n\n特别要注意的是 `0 ^ 0 = 1`。", "`Mul a b`, with notation `a * b`, is the usual\n product of natural numbers. Internally it is\n via two axioms:\n\n * `mul_zero a : a * 0 = 0`\n\n * `mul_succ a b : a * succ b = a * b + a`\n\nOther theorems about naturals, such as `zero_mul`,\nare proved by induction from these two basic theorems.": "`Mul a b`,其符号表示为 `a * b`,是自然数的常规乘积。它是通过两条规则定义的:\n\n* `mul_zero a : a * 0 = 0`\n\n* `mul_succ a b : a * succ b = a * b + a`\n\n关于自然数的其他定理,比如 `zero_mul`,都是通过从这两个基本定理进行归纳证明得到的。", - "`Add a b`, with notation `a + b`, is\nthe usual sum of natural numbers. Internally it is defined\nvia the following two hypotheses:\n\n* `add_zero a : a + 0 = a`\n\n* `add_succ a b : a + succ b = succ (a + b)`\n\nOther theorems about naturals, such as `zero_add a : 0 + a = a`, are proved\nby induction using these two basic theorems.\"": + "`Add a b`, with notation `a + b`, is\nthe usual sum of natural numbers. Internally it is defined\nvia the following two hypotheses:\n\n* `add_zero a : a + 0 = a`\n\n* `add_succ a b : a + succ b = succ (a + b)`\n\nOther theorems about naturals, such as `zero_add a : 0 + a = a`, are proved\nby induction using these two basic theorems.": "`Add a b`,符号为 `a + b`,是\n自然数之和。\n通过以下两个假设定义:\n\n* `add_zero a : a + 0 = a`\n\n* `add_succ a b : a + succ b = succ (a + b)`\n\n其他关于自然数的定理,例如 `zero_add a : 0 + a = a`,也\n通过数学归纳法使用这两个基本定义进行证明。", "[final boss music]": "【最终Boss背景音乐】", "[dramatic music]. Now are you ready to face the first boss of the game?": "【背景音乐】现在你准备好面对游戏里的第一个boss了吗?", "[boss battle music]\n\nLook in your inventory to see the proofs you have available.\nThese should be enough.": "【Boss战音乐】\n\n查看您的库存以查看您拥有的可用定理。\n这些应该足够了。", - "You've now seen all the tactics you need to beat the final boss of the game.\nYou can begin the journey towards this boss by entering Multiplication World.\n\nOr you can go off the beaten track and learn some new tactics in Implication\nWorld. These tactics let you prove more facts about addition, such as\nhow to deduce `a = 0` from `x + a = x`.\n\nClick \"Leave World\" and make your choice.": + "You've now seen all the tactics you need to beat the final boss of the game.\nYou can begin the journey towards this boss by entering Multiplication World.\n\nOr you can go off the beaten track and learn some new tactics in Implication\nWorld. These tactics let you prove more facts about addition, such as\nhow to deduce `a = 0` from `x + a = x`.\n\nClick \"Home\" and make your choice.": "你现在已经掌握了击败游戏最终 BOSS 所需的所有策略。\n你可以进入乘法世界,开始征服 BOSS 的冒险之旅。\n\n或者,你可以离开常规路线,在蕴涵世界中学习一些新的策略。\n这些策略可以让你证明更多关于加法的事实,例如从 `x + a = x` 推导 `a = 0`。\n\n点击“离开世界”,做出你的选择吧。", "You want to use `add_right_eq_zero`, which you already\nproved, but you'll have to start with `symm at` your hypothesis.": "你想使用 `add_right_eq_zero`,这是你已经证明过的,但你需要从对你的假设使用 `symm at` 开始。", @@ -495,7 +495,7 @@ "请注意,`succ a + «{d}»` 的意思是 `(succ a) + «{d}»`。将你的光标放在目标或假设中的任何 `succ` 上,以查看它确切的含义。", "Nice! You've proved `succ_inj`!\nLet's now prove Peano's other axiom, that successors can't be $0$.": "好的!您已经证明了 `succ_inj`!\n现在让我们证明皮亚诺的另一个公理,后继数不可能是 $0$。", - "Nice!\n\nThe next step in the development of order theory is to develop\nthe theory of the interplay between `≤` and multiplication.\nIf you've already done Multiplication World, you're now ready for\nAdvanced Multiplication World. Click on \"Leave World\" to access it.": + "Nice!\n\nThe next step in the development of order theory is to develop\nthe theory of the interplay between `≤` and multiplication.\nIf you've already done Multiplication World, you're now ready for\nAdvanced Multiplication World. Click on \"Home\" to access it.": "很棒!\n\n发展序理论的下一步是发展 `≤` 与乘法之间相互作用的理论。\n如果你已经完成了乘法世界,那么就可以进入高级乘法世界。点击 \"离开世界 \"进入。", "Nice!": "好的!", "Next turn `1` into `succ 0` with `rw [one_eq_succ_zero]`.": @@ -631,7 +631,7 @@ "我们应该如何定义 `37 * x`?就像加法一样,我们需要在 $x=0$ 和 $x$ 是后继数时给出定义。\n\n0的情况很简单:我们定义 `37 * 0` 为 `0`。现在假设我们知道 `37 * d`。`37 * succ d` 应该是什么呢?嗯,那是 $d+1$ 个 $37$,它应该是 `37 * d + 37`。\n\n以下是 Lean 中的定义。\n\n * `mul_zero a : a * 0 = 0`\n * `mul_succ a d : a * succ d = a * d + a`\n\n在这个世界中,我们不仅要证明关于乘法的事实,如 `a * b = b * a`,我们还必须证明乘法与加法相互作用的事实,如 `a * (b + c) = a * b + a * c`。\n让我们开始吧。", "How about this for a proof:\n```\nrepeat rw [add_comm n]\nexact add_right_cancel a b n\n```": "下面这个证明怎么样:\n```\nrepeat rw [add_comm n]\nexact add_right_cancel a b n\n```", - "How about this for a proof:\n\n```\nrw [add_comm]\nexact add_right_eq_zero b a\n```\n\nThat's the end of Advanced Addition World! You'll need these theorems\nfor the next world, `≤` World. Click on \"Leave World\" to access it.": + "How about this for a proof:\n\n```\nrw [add_comm]\nexact add_right_eq_zero b a\n```\n\nThat's the end of Advanced Addition World! You'll need these theorems\nfor the next world, `≤` World. Click on \"Home\" to access it.": "这个证明怎么样:\n\n```\nrw [add_comm]\nexact add_right_eq_zero b a\n```\n\n这里就是高级加法世界的结尾了!你将带着这些定理\n进入下一个世界,`≤` 世界。点击“离开世界”来访问它。", "Here's what I was thinking of:\n```\napply mul_left_ne_zero at h\napply one_le_of_ne_zero at h\napply mul_le_mul_right 1 b a at h\nrw [one_mul, mul_comm] at h\nexact h\n```": "我是这么想的:\n```\napply mul_left_ne_zero at h\napply one_le_of_ne_zero at h\napply mul_le_mul_right 1 b a at h\nrw [one_mul, mul_comm] at h\nexact h\n```", @@ -645,7 +645,7 @@ "这是一个解决方案,不唯一:\n```\ninduction c with d hd\nrw [add_zero, mul_zero, add_zero]\nrfl\nrw [add_succ, mul_succ, hd, mul_succ, add_assoc]\nrfl\n```\n\n在 `a` 或 `b` 上进行数学归纳也可以,但需要多步骤。", "Here's my proof:\n```\nrw [mul_comm, mul_add]\nrepeat rw [mul_comm c]\nrfl\n```": "这是我的证明:\n```\nrw [mul_comm, mul_add]\nrepeat rw [mul_comm c]\nrfl\n```", - "Here's my proof:\n```\nintro h\nrw [add_succ, add_succ, add_zero] at h\nrepeat apply succ_inj at h\napply zero_ne_succ at h\nexact h\n```\n\nEven though Lean is a theorem prover, right now it's pretty clear that we have not\ndeveloped enough material to make it an adequate calculator. In Algorithm\nWorld, a more computer-sciency world, we will develop machinery which makes\nquestions like this much easier, and goals like $20 + 20 ≠ 41$ feasible.\nAlternatively you can do more mathematics in Advanced Addition World, where we prove\nthe lemmas needed to get a working theory of inequalities. Click \"Leave World\" and\ndecide your route.": + "Here's my proof:\n```\nintro h\nrw [add_succ, add_succ, add_zero] at h\nrepeat apply succ_inj at h\napply zero_ne_succ at h\nexact h\n```\n\nEven though Lean is a theorem prover, right now it's pretty clear that we have not\ndeveloped enough material to make it an adequate calculator. In Algorithm\nWorld, a more computer-sciency world, we will develop machinery which makes\nquestions like this much easier, and goals like $20 + 20 ≠ 41$ feasible.\nAlternatively you can do more mathematics in Advanced Addition World, where we prove\nthe lemmas needed to get a working theory of inequalities. Click \"Home\" and\ndecide your route.": "这是一个证明:\n```\nintro h\nrw [add_succ, add_succ, add_zero] at h\nrepeat apply succ_inj at h\napply zero_ne_succ at h\nexact h\n```\n\n\n尽管 Lean 是一个定理证明器,但很明显我们还没有开发足够的材料使其成为一个合适的计算器。在算法世界,一个更具计算机科学色彩的世界中,我们将开发使这类问题变得更容易的机制(比如快速证明 $20 + 20 \\neq 41$ )。或者,你也可以在高级加法世界中进行更多数学学习,我们在那里证明了建立不等式理论所需的引理。点击“离开世界”并决定你的路线。", "Here's my proof:\n```\ncases x with y\nleft\nrfl\nrw [one_eq_succ_zero] at hx ⊢\napply succ_le_succ at hx\napply le_zero at hx\nrw [hx]\nright\nrfl\n```\n\nIf you solved this level then you should be fine with the next level!": "这是我的证明:\n```\ncases x with y\nleft\nrfl\nrw [one_eq_succ_zero] at hx ⊢\napply succ_le_succ at hx\napply le_zero at hx\nrw [hx]\nright\nrfl\n```\n\n如果你解决了这个关卡,那么你应该可以顺利进入下一个关卡!", @@ -665,7 +665,7 @@ "在这里,我们想要分别处理 `b = 0` 和 `b ≠ 0` 的情况,\n所以从 `cases b with d` 开始。", "Here we begin to\ndevelop an algorithm which, given two naturals `a` and `b`, returns the answer\nto \"does `a = b`?\"\n\nHere is the algorithm. First note that `a` and `b` are numbers, and hence\nare either `0` or successors.\n\n*) If `a` and `b` are both `0`, return \"yes\".\n\n*) If one is `0` and the other is `succ n`, return \"no\".\n\n*) If `a = succ m` and `b = succ n`, then return the answer to \"does `m = n`?\"\n\nOur job now is to *prove* that this algorithm always gives the correct answer. The proof that\n`0 = 0` is `rfl`. The proof that `0 ≠ succ n` is `zero_ne_succ n`, and the proof\nthat `succ m ≠ 0` is `succ_ne_zero m`. The proof that if `h : m = n` then\n`succ m = succ n` is `rw [h]` and then `rfl`. This level is a proof of the one\nremaining job we have to do: if `a ≠ b` then `succ a ≠ succ b`.": "我们开始开发一个算法,给定两个自然数 `a` 和 `b`,返回对“`a = b`?”的回答。\n\n这是算法。首先注意到 `a` 和 `b` 是数字,因此要么是 `0` 要么是后继者。\n\n* 如果 `a` 和 `b` 都是 `0`,返回“是”。\n* 如果一个是 `0` 而另一个是 `succ n`,返回“否”。\n* 如果 `a = succ m` 且 `b = succ n`,那么返回对“`m = n`?”的答案。\n\n现在我们的任务是*证明*这个算法总能给出正确的答案。证明 `0 = 0` 是 `rfl`。证明 `0 ≠ succ n` 的是 `zero_ne_succ n`,证明 `succ m ≠ 0` 的是 `succ_ne_zero m`。如果有假设 `h : m = n`,那么证明 `succ m = succ n` 可以使用 `rw [h]` 然后 `rfl`。这一关是证明我们要做的剩余工作之一:如果 `a ≠ b`,那么 `succ a ≠ succ b`。", - "Here is an example proof of 2+2=4 showing off various techniques.\n\n```lean\nnth_rewrite 2 [two_eq_succ_one] -- only change the second `2` to `succ 1`.\nrw [add_succ]\nrw [one_eq_succ_zero]\nrw [add_succ, add_zero] -- two rewrites at once\nrw [← three_eq_succ_two] -- change `succ 2` to `3`\nrw [← four_eq_succ_three]\nrfl\n```\n\nOptional extra: you can run this proof yourself. Switch the game into \"Editor mode\" by clicking\non the `` button in the top right. You can now see your proof\nwritten as several lines of code. Move your cursor between lines to see\nthe goal state at any point. Now cut and paste your code elsewhere if you\nwant to save it, and paste the above proof in instead. Move your cursor\naround to investigate. When you've finished, click the `>_` button in the top right to\nmove back into \"Typewriter mode\".\n\nYou have finished tutorial world!\nClick \"Leave World\" to go back to the\noverworld, and select Addition World, where you will learn\nabout the `induction` tactic.": + "Here is an example proof of 2+2=4 showing off various techniques.\n\n```lean\nnth_rewrite 2 [two_eq_succ_one] -- only change the second `2` to `succ 1`.\nrw [add_succ]\nrw [one_eq_succ_zero]\nrw [add_succ, add_zero] -- two rewrites at once\nrw [← three_eq_succ_two] -- change `succ 2` to `3`\nrw [← four_eq_succ_three]\nrfl\n```\n\nOptional extra: you can run this proof yourself. Switch the game into \"Editor mode\" by clicking\non the `` button in the top right. You can now see your proof\nwritten as several lines of code. Move your cursor between lines to see\nthe goal state at any point. Now cut and paste your code elsewhere if you\nwant to save it, and paste the above proof in instead. Move your cursor\naround to investigate. When you've finished, click the `>_` button in the top right to\nmove back into \"Typewriter mode\".\n\nYou have finished tutorial world!\nClick \"Home\" to go back to the\noverworld, and select Addition World, where you will learn\nabout the `induction` tactic.": "下面是一个证明 2+2=4 的例子,展示了各种技巧。\n\n```lean\nnth_rewrite 2 [two_eq_succ_one] -- 只将第二个 `2 ` 改为 `succ 1` 。\nrw [add_succ]\nrw [one_eq_succ_zero]\nrw [add_succ, add_zero] -- 一次改写两个内容\nrw [← three_eq_succ_two] -- 将 `succ 2` 改为 `3`\nrw [← four_eq_succ_three] 。\nrfl\n```\n\n可选附加功能:你可以自己运行这个证明。点击右上角的\n右上角的 `` 按钮,将游戏切换到 \"编辑器模式\"。现在你可以看到你的证明\n被写成了几行代码。在各行代码之间移动光标,即可查看\n目标状态。现在,如果想保存代码,你就要将代码剪切并粘贴到其他地方\n,请将上述证明粘贴进去。移动光标\n进行研究。完成后,点击右上角的 `>_` 按钮,回到 \"打字机模式\"。\n回到 \"打字机模式\"。\n\n您已经完成了 \"教程世界\"!\n点击 \"离开世界 \"回到世界选择界面\n选择 \"加法世界\",在这里您将学习\n`induction ` 策略。", "Having to rearrange variables manually using commutativity and\nassociativity is very tedious. We start by reminding you of this. `add_left_comm`\nis a key component in the first algorithm which we'll explain, but we need\nto prove it manually.\n\nRemember that you can do precision commutativity rewriting\nwith things like `rw [add_comm b c]`. And remember that\n`a + b + c` means `(a + b) + c`.": "我们首先提醒您一点,手动使用交换律和结合律来重新排列变量是非常繁琐的。\n`add_left_comm` 是我们将要解释的第一个算法中的关键组件,但我们需要手动证明它。\n\n请记住,您可以使用 `rw [add_comm b c]` 之类的命令进行精确的交换律重写。并记住 `a + b + c` 表示 `(a + b) + c`。", @@ -705,7 +705,7 @@ "对于所有自然数 $a$ 和 $b$,我们有\n$(\\operatorname{succ}\\ a) \\times b = a\\times b + b$。", "First execute `rw [h]` to replace the `y` with `x + 7`.": "首先执行 `rw [h]` 将 `y` 替换为 `x + 7`。", - "Finally use a targetted `add_comm` to switch `b` and `d`": + "Finally use a targeted `add_comm` to switch `b` and `d`": "最后,使用有针对性的 `add_comm` 来交换 `b` 和 `d", "Fermat's Last Theorem": "费马大定理", "Every number in Lean is either $0$ or a successor. We know how to add $0$,\nbut we need to figure out how to add successors. Let's say we already know\nthat `37 + d = q`. What should the answer to `37 + succ d` be? Well,\n`succ d` is one bigger than `d`, so `37 + succ d` should be `succ q`,\nthe number one bigger than `q`. More generally `x + succ d` should\nbe `succ (x + d)`. Let's add this as a lemma.\n\n* `add_succ x d : x + succ d = succ (x + d)`\n\nIf you ever see `... + succ ...` in your goal, `rw [add_succ]` is\nnormally a good idea.\n\nLet's now prove that `succ n = n + 1`. Figure out how to get `+ succ` into\nthe picture, and then `rw [add_succ]`. Switch between the `+` (addition) and\n`012` (numerals) tabs under \"Theorems\" on the right to\nsee which proofs you can rewrite.": @@ -771,8 +771,8 @@ "2 + 2 ≠ 5": "2 + 2 ≠ 5", "1 ≠ 0": "1 ≠ 0", "0 ≤ x": "0 ≤ x", - "*Game version: 4.3*\n\n*Recent additions: bug fixes*\n\n## Progress saving\n\nThe game stores your progress in your local browser storage.\nIf you delete it, your progress will be lost!\n\nWarning: In most browsers, deleting cookies will also clear the local storage\n(or \"local site data\"). Make sure to download your game progress first!\n\n## Credits\n\n* **Creators:** Kevin Buzzard, Jon Eugster\n* **Original Lean3-version:** Kevin Buzzard, Mohammad Pedramfar\n* **Game Engine:** Alexander Bentkamp, Jon Eugster, Patrick Massot\n* **Additional levels:** Sian Carey, Ivan Farabella, Archie Browne.\n* **Additional thanks:** All the student beta testers, all the schools\nwho invited Kevin to speak, and all the schoolkids who asked him questions\nabout the material.\n\n## Resources\n\n* The [Lean Zulip chat](https://leanprover.zulipchat.com/) forum\n* [Original Lean3 version](https://www.ma.imperial.ac.uk/~buzzard/xena/natural_number_game/) (no longer maintained)\n\n## Problems?\n\nPlease ask any questions about this game in the\n[Lean Zulip chat](https://leanprover.zulipchat.com/) forum, for example in\nthe stream \"New Members\". The community will happily help. Note that\nthe Lean Zulip chat is a professional research forum.\nPlease use your full real name there, stay on topic, and be nice. If you're\nlooking for somewhere less formal (e.g. you want to post natural number\ngame memes) then head on over to the [Lean Discord](https://discord.gg/WZ9bs9UCvx).\n\nAlternatively, if you experience issues / bugs you can also open github issues:\n\n* For issues with the game engine, please open an\n[issue at the lean4game](https://github.com/leanprover-community/lean4game/issues) repo.\n* For issues about the game's content, please open an\n[issue at the NNG](https://github.com/hhu-adam/NNG4/issues) repo.": - "*游戏版本:4.2*\n\n*最近新增:不等式世界,算法世界*\n\n## 进度保存\n\n游戏会将你的进度存储在本地浏览器存储中。\n如果你删除它,你的进度将会丢失!\n\n警告:在大多数浏览器中,删除 cookie 也会清除本地存储(或“本地网站数据”)。确保首先下载你的游戏进度!\n\n## 致谢\n\n* **创建者:** Kevin Buzzard, Jon Eugster\n* **原始 Lean3 版本:** Kevin Buzzard, Mohammad Pedramfar\n* **游戏引擎:** Alexander Bentkamp, Jon Eugster, Patrick Massot\n* **额外关卡:** Sian Carey, Ivan Farabella, Archie Browne.\n* **特别感谢:** 所有学生测试者,所有邀请 Kevin 发表演讲的学校,以及向他提出关于材料问题的所有学生。\n\n## 资源\n\n* [Lean Zulip 聊天](https://leanprover.zulipchat.com/) 论坛\n* [原始 Lean3 版本](https://www.ma.imperial.ac.uk/~buzzard/xena/natural_number_game/)(不再维护)\n\n## 有问题吗?\n\n请在 [Lean Zulip 聊天](https://leanprover.zulipchat.com/) 论坛提出关于这个游戏的任何问题,例如在 “新成员” 流中。社区会乐意帮忙。请注意,Lean Zulip 聊天是一个专业研究论坛。请使用您的全名,保持话题相关,且友好。如果你正在寻找一个不那么正式的地方(例如,你想发布自然数游戏的表情包),那么可以前往 [Lean Discord](https://discord.gg/WZ9bs9UCvx)。\n\n另外,如果你遇到问题/漏洞,你也可以在 github 上提出问题:\n\n* 对于游戏引擎的问题,请在 [lean4game](https://github.com/leanprover-community/lean4game/issues) 仓库提出问题。\n* 对于游戏内容的问题,请在 [NNG](https://github.com/hhu-adam/NNG4/issues) 仓库提出问题。", + "*Game version: 4.3*\n\n*Recent additions: bug fixes*\n\n## Progress saving\n\nThe game stores your progress in your local browser storage.\nIf you delete it, your progress will be lost!\n\nWarning: In most browsers, deleting cookies will also clear the local storage\n(or \"local site data\"). Make sure to download your game progress first!\n\n## Credits\n\n* **Creators:** Kevin Buzzard, Jon Eugster\n* **Original Lean3-version:** Kevin Buzzard, Mohammad Pedramfar\n* **Game Engine:** Alexander Bentkamp, Jon Eugster, Patrick Massot\n* **Additional levels:** Sian Carey, Ivan Farabella, Archie Browne.\n* **Additional thanks:** All the student beta testers, all the schools\nwho invited Kevin to speak, and all the schoolkids who asked him questions\nabout the material.\n\n## Resources\n\n* The [Lean Zulip chat](https://leanprover.zulipchat.com/) forum\n* [Original Lean3 version](https://github.com/ImperialCollegeLondon/natural_number_game/) (no longer maintained)\n\n## Problems?\n\nPlease ask any questions about this game in the\n[Lean Zulip chat](https://leanprover.zulipchat.com/) forum, for example in\nthe stream \"New Members\". The community will happily help. Note that\nthe Lean Zulip chat is a professional research forum.\nPlease use your full real name there, stay on topic, and be nice. If you're\nlooking for somewhere less formal (e.g. you want to post natural number\ngame memes) then head on over to the [Lean Discord](https://discord.gg/WZ9bs9UCvx).\n\nAlternatively, if you experience issues / bugs you can also open github issues:\n\n* For issues with the game engine, please open an\n[issue at the lean4game](https://github.com/leanprover-community/lean4game/issues) repo.\n* For issues about the game's content, please open an\n[issue at the NNG](https://github.com/hhu-adam/NNG4/issues) repo.": + "*游戏版本:4.2*\n\n*最近新增:不等式世界,算法世界*\n\n## 进度保存\n\n游戏会将你的进度存储在本地浏览器存储中。\n如果你删除它,你的进度将会丢失!\n\n警告:在大多数浏览器中,删除 cookie 也会清除本地存储(或“本地网站数据”)。确保首先下载你的游戏进度!\n\n## 致谢\n\n* **创建者:** Kevin Buzzard, Jon Eugster\n* **原始 Lean3 版本:** Kevin Buzzard, Mohammad Pedramfar\n* **游戏引擎:** Alexander Bentkamp, Jon Eugster, Patrick Massot\n* **额外关卡:** Sian Carey, Ivan Farabella, Archie Browne.\n* **特别感谢:** 所有学生测试者,所有邀请 Kevin 发表演讲的学校,以及向他提出关于材料问题的所有学生。\n\n## 资源\n\n* [Lean Zulip 聊天](https://leanprover.zulipchat.com/) 论坛\n* [原始 Lean3 版本](https://github.com/ImperialCollegeLondon/natural_number_game/)(不再维护)\n\n## 有问题吗?\n\n请在 [Lean Zulip 聊天](https://leanprover.zulipchat.com/) 论坛提出关于这个游戏的任何问题,例如在 “新成员” 流中。社区会乐意帮忙。请注意,Lean Zulip 聊天是一个专业研究论坛。请使用您的全名,保持话题相关,且友好。如果你正在寻找一个不那么正式的地方(例如,你想发布自然数游戏的表情包),那么可以前往 [Lean Discord](https://discord.gg/WZ9bs9UCvx)。\n\n另外,如果你遇到问题/漏洞,你也可以在 github 上提出问题:\n\n* 对于游戏引擎的问题,请在 [lean4game](https://github.com/leanprover-community/lean4game/issues) 仓库提出问题。\n* 对于游戏内容的问题,请在 [NNG](https://github.com/hhu-adam/NNG4/issues) 仓库提出问题。", "$x=37\\implies x=37$.": "$x=37\\implies x=37$ 。", "$x+y=x\\implies y=0$.": "$x+y=x\\implies y=0$.", "$x+1=y+1 \\implies x=y$.": "$x+1=y+1\\implies x=y$。", @@ -811,7 +811,7 @@ "## 概述\n\n如果 `n` 是一个数字,那么 `cases n with d` 会将目标分解成两个目标,一个是 `n = 0`,另一个是 `n = succ d`。\n\n如果 `h` 是一个证明(例如一个假设),那么 `cases h with...` 会将证明分解成用来证明它的各个部分。\n\n## 示例\n\n如果 `n : ℕ` 是一个数字,那么 `cases n with d` 会将目标分解成两个目标,一个是 `n` 被替换为 0,另一个是 `n` 被替换为 `succ d`。这对应于数学上的观点,即每个自然数要么是 `0`,要么是一个后继数。\n\n## 示例\n\n如果 `h : P ∨ Q` 是一个假设,那么 `cases h with hp hq` 会将一个目标变成两个目标,一个有假设 `hp : P`,另一个有假设 `hq : Q`。\n\n## 示例\n\n如果 `h : False` 是一个假设,那么 `cases h` 会将一个目标变成没有目标,因为没有方法可以证明 `False`!如果你没有剩余的目标,你就完成了这个关卡。\n\n## 示例\n\n如果 `h : a ≤ b` 是一个假设,那么 `cases h with c hc` 会创建一个新的数字 `c` 和一个证明 `hc : b = a + c`。这是因为 `a ≤ b` 的*定义*是 `∃ c, b = a + c`。", "## Summary\n\nIf `n : ℕ` is an object, and the goal mentions `n`, then `induction n with d hd`\nattempts to prove the goal by induction on `n`, with the inductive\nvariable in the successor case being `d`, and the inductive hypothesis being `hd`.\n\n### Example:\nIf the goal is\n```\n0 + n = n\n```\n\nthen\n\n`induction n with d hd`\n\nwill turn it into two goals. The first is `0 + 0 = 0`;\nthe second has an assumption `hd : 0 + d = d` and goal\n`0 + succ d = succ d`.\n\nNote that you must prove the first\ngoal before you can access the second one.": "## 概述\n\n如果 `n : ℕ` 是一个对象,并且目标提到了 `n`,那么 `induction n with d hd`\n尝试通过对 `n` 进行归纳来证明目标,其中后继数情况下的归纳变量是 `d`,归纳假设是 `hd`。\n\n### 例子:\n如果目标是\n```\n0 + n = n\n```\n\n那么\n\n`induction n with d hd`\n\n将把它变成两个目标。第一个是 `0 + 0 = 0`;\n第二个有一个假设 `hd : 0 + d = d` 和目标\n`0 + succ d = succ d` 。\n\n注意你必须先证明第一个然后才能证第二个。", - "## Summary\n\nIf `h` is a proof of an equality `X = Y`, then `rw [h]` will change\nall `X`s in the goal to `Y`s. It's the way to \\\"substitute in\\\".\n\n## Variants\n\n* `rw [← h]` (changes `Y`s to `X`s; get the back arrow by typing `\\left ` or `\\l`.)\n\n* `rw [h1, h2]` (a sequence of rewrites)\n\n* `rw [h] at h2` (changes `X`s to `Y`s in hypothesis `h2`)\n\n* `rw [h] at h1 h2 ⊢` (changes `X`s to `Y`s in two hypotheses and the goal;\nget the `⊢` symbol with `\\|-`.)\n\n* `repeat rw [add_zero]` will keep changing `? + 0` to `?`\nuntil there are no more matches for `? + 0`.\n\n* `nth_rewrite 2 [h]` will change only the second `X` in the goal to `Y`.\n\n### Example:\n\nIf you have the assumption `h : x = y + y` and your goal is\n```\nsucc (x + 0) = succ (y + y)\n```\n\nthen\n\n`rw [add_zero]`\n\nwill change the goal into `succ x = succ (y + y)`, and then\n\n`rw [h]`\n\nwill change the goal into `succ (y + y) = succ (y + y)`, which\ncan be solved with `rfl`.\n\n### Example:\n\nYou can use `rw` to change a hypothesis as well.\nFor example, if you have two hypotheses\n```\nh1 : x = y + 3\nh2 : 2 * y = x\n```\nthen `rw [h1] at h2` will turn `h2` into `h2 : 2 * y = y + 3`.\n\n## Common errors\n\n* You need the square brackets. `rw h` is never correct.\n\n* If `h` is not a *proof* of an *equality* (a statement of the form `A = B`),\nfor example if `h` is a function or an implication,\nthen `rw` is not the tactic you want to use. For example,\n`rw [P = Q]` is never correct: `P = Q` is the theorem *statement*,\nnot the proof. If `h : P = Q` is the proof, then `rw [h]` will work.\n\n## Details\n\nThe `rw` tactic is a way to do \\\"substituting in\\\". There\nare two distinct situations where you can use this tactic.\n\n1) Basic usage: if `h : A = B` is an assumption or\nthe proof of a theorem, and if the goal contains one or more `A`s, then `rw [h]`\nwill change them all to `B`s. The tactic will error\nif there are no `A`s in the goal.\n\n2) Advanced usage: Assumptions coming from theorem proofs\noften have missing pieces. For example `add_zero`\nis a proof that `? + 0 = ?` because `add_zero` really is a function,\nand `?` is the input. In this situation `rw` will look through the goal\nfor any subterm of the form `x + 0`, and the moment it\nfinds one it fixes `?` to be `x` then changes all `x + 0`s to `x`s.\n\nExercise: think about why `rw [add_zero]` changes the term\n`(0 + 0) + (x + 0) + (0 + 0) + (x + 0)` to\n`0 + (x + 0) + 0 + (x + 0)`\n\nIf you can't remember the name of the proof of an equality, look it up in\nthe list of lemmas on the right.\n\n## Targetted usage\n\nIf your goal is `b + c + a = b + (a + c)` and you want to rewrite `a + c`\nto `c + a`, then `rw [add_comm]` will not work because Lean finds another\naddition first and swaps those inputs instead. Use `rw [add_comm a c]` to\nguarantee that Lean rewrites `a + c` to `c + a`. This works because\n`add_comm` is a proof that `?1 + ?2 = ?2 + ?1`, `add_comm a` is a proof\nthat `a + ? = ? + a`, and `add_comm a c` is a proof that `a + c = c + a`.\n\nIf `h : X = Y` then `rw [h]` will turn all `X`s into `Y`s.\nIf you only want to change the 37th occurrence of `X`\nto `Y` then do `nth_rewrite 37 [h]`.": + "## Summary\n\nIf `h` is a proof of an equality `X = Y`, then `rw [h]` will change\nall `X`s in the goal to `Y`s. It's the way to \\\"substitute in\\\".\n\n## Variants\n\n* `rw [← h]` (changes `Y`s to `X`s; get the back arrow by typing `\\left ` or `\\l`.)\n\n* `rw [h1, h2]` (a sequence of rewrites)\n\n* `rw [h] at h2` (changes `X`s to `Y`s in hypothesis `h2`)\n\n* `rw [h] at h1 h2 ⊢` (changes `X`s to `Y`s in two hypotheses and the goal;\nget the `⊢` symbol with `\\|-`.)\n\n* `repeat rw [add_zero]` will keep changing `? + 0` to `?`\nuntil there are no more matches for `? + 0`.\n\n* `nth_rewrite 2 [h]` will change only the second `X` in the goal to `Y`.\n\n### Example:\n\nIf you have the assumption `h : x = y + y` and your goal is\n```\nsucc (x + 0) = succ (y + y)\n```\n\nthen\n\n`rw [add_zero]`\n\nwill change the goal into `succ x = succ (y + y)`, and then\n\n`rw [h]`\n\nwill change the goal into `succ (y + y) = succ (y + y)`, which\ncan be solved with `rfl`.\n\n### Example:\n\nYou can use `rw` to change a hypothesis as well.\nFor example, if you have two hypotheses\n```\nh1 : x = y + 3\nh2 : 2 * y = x\n```\nthen `rw [h1] at h2` will turn `h2` into `h2 : 2 * y = y + 3`.\n\n## Common errors\n\n* You need the square brackets. `rw h` is never correct.\n\n* If `h` is not a *proof* of an *equality* (a statement of the form `A = B`),\nfor example if `h` is a function or an implication,\nthen `rw` is not the tactic you want to use. For example,\n`rw [P = Q]` is never correct: `P = Q` is the theorem *statement*,\nnot the proof. If `h : P = Q` is the proof, then `rw [h]` will work.\n\n## Details\n\nThe `rw` tactic is a way to do \\\"substituting in\\\". There\nare two distinct situations where you can use this tactic.\n\n1) Basic usage: if `h : A = B` is an assumption or\nthe proof of a theorem, and if the goal contains one or more `A`s, then `rw [h]`\nwill change them all to `B`s. The tactic will error\nif there are no `A`s in the goal.\n\n2) Advanced usage: Assumptions coming from theorem proofs\noften have missing pieces. For example `add_zero`\nis a proof that `? + 0 = ?` because `add_zero` really is a function,\nand `?` is the input. In this situation `rw` will look through the goal\nfor any subterm of the form `x + 0`, and the moment it\nfinds one it fixes `?` to be `x` then changes all `x + 0`s to `x`s.\n\nExercise: think about why `rw [add_zero]` changes the term\n`(0 + 0) + (x + 0) + (0 + 0) + (x + 0)` to\n`0 + (x + 0) + 0 + (x + 0)`\n\nIf you can't remember the name of the proof of an equality, look it up in\nthe list of lemmas on the right.\n\n## Targeted usage\n\nIf your goal is `b + c + a = b + (a + c)` and you want to rewrite `a + c`\nto `c + a`, then `rw [add_comm]` will not work because Lean finds another\naddition first and swaps those inputs instead. Use `rw [add_comm a c]` to\nguarantee that Lean rewrites `a + c` to `c + a`. This works because\n`add_comm` is a proof that `?1 + ?2 = ?2 + ?1`, `add_comm a` is a proof\nthat `a + ? = ? + a`, and `add_comm a c` is a proof that `a + c = c + a`.\n\nIf `h : X = Y` then `rw [h]` will turn all `X`s into `Y`s.\nIf you only want to change the 37th occurrence of `X`\nto `Y` then do `nth_rewrite 37 [h]`.": "## 概述\n\n如果 `h` 是一个等式 `X = Y` 的证明,那么 `rw [h]` 将会把目标中所有的 `X` 改为 `Y`。这是一种“代入”的方式。\n\n## 变体\n\n* `rw [← h]`(将 `Y` 改为 `X`;通过输入 `\\left ` 或 `\\l` 获取反向箭头。)\n\n* `rw [h1, h2]`(一系列重写)\n\n* `rw [h] at h2`(在假设 `h2` 中将 `X` 改为 `Y`)\n\n* `rw [h] at h1 h2 ⊢`(在两个假设和目标中将 `X` 改为 `Y`;通过输入 `\\|-` 获取 `⊢` 符号。)\n\n* `repeat rw [add_zero]` 将会不断地把 `? + 0` 改为 `?`,直到没有更多的 `? + 0` 匹配为止。\n\n* `nth_rewrite 2 [h]` 只会把目标中的第二个 `X` 改为 `Y`。\n\n### 示例:\n\n如果你有假设 `h : x = y + y` 并且你的目标是\n```\nsucc (x + 0) = succ (y + y)\n```\n\n那么\n\n`rw [add_zero]`\n\n将会把目标改为 `succ x = succ (y + y)`,然后\n\n`rw [h]`\n\n将会把目标改为 `succ (y + y) = succ (y + y)`,这个可以通过 `rfl` 解决。\n\n### 示例:\n\n你也可以使用 `rw` 来改变一个假设。例如,如果你有两个假设\n```\nh1 : x = y + 3\nh2 : 2 * y = x\n```\n那么 `rw [h1] at h2` 将会把 `h2` 变为 `h2 : 2 * y = y + 3`。\n\n## 常见错误\n\n* 你需要方括号。`rw h` 是不正确的。\n\n* 如果 `h` 不是一个*等式*的*证明*(形式为 `A = B` 的声明),例如如果 `h` 是一个函数或蕴含,那么 `rw` 不是你想要使用的策略。例如,`rw [P = Q]` 永远不正确, 因为`P = Q` 是定理的*陈述*,而不是证明。但如果 `h : P = Q` 是证明,那么 `rw [h]` 将会起作用。\n\n## 详情\n\n`rw` 策略是一种进行“代入”的方式。有两种不同的情况你可以使用这个策略。\n\n1) 基本使用:如果 `h : A = B` 是一个假设或定理的证明,并且目标中包含一个或多个 `A`,那么 `rw [h]` 会把它们全部改为 `B`。如果目标中没有 `A`,策略会报错。\n\n2) 高级使用:来自定理证明的假设经常有缺失的部分。例如 `add_zero` 是一个证明,表示 `? + 0 = ?`,因为 `add_zero` 实际上是一个函数,而 `?` 是输入。在这种情况下,`rw` 会在目标中查找任何形式为 `x + 0` 的子项,一旦找到,它就将 `?` 定位为 `x`,然后把所有的 `x + 0` 改为 `x`。\n\n练习:思考为什么 `rw [add_zero]` 会把项 `(0 + 0) + (x + 0) + (0 + 0) + (x + 0)` 改为 `0 + (x + 0) + 0 + (x + 0)`\n\n如果你不能记住等式证明的名称,请在右侧的定理列表中查找。\n\n## 针对性使用\n\n如果你的目标是 `b + c + a = b + (a + c)` 并且你想把 `a + c` 重写为 `c + a`,那么 `rw [add_comm]` 将不起作用,因为 Lean 会先找到另一个加法并交换它。使用 `rw [add_comm a c]` 来保证 Lean 将 `a + c` 重写为 `c + a`。这是因为 `add_comm` 是一个证明,表示 `?1 + ?2 = ?2 + ?1`,`add_comm a` 是一个证明,表示 `a + ? = ? + a`,而 `add_comm a c` 是另一个证明,表示 `a + c = c + a`。\n\n如果 `h : X = Y`,那么 `rw [h]` 将会把所有的 `X` 变为 `Y`。如果你只想改变第37次出现的 `X` 为 `Y`,那么可以使用 `nth_rewrite 37 [h]`。", "## Summary\n\nIf `h : X = Y` and there are several `X`s in the goal, then\n`nth_rewrite 3 [h]` will just change the third `X` to a `Y`.\n\n## Example\n\nIf the goal is `2 + 2 = 4` then `nth_rewrite 2 [two_eq_succ_one]`\nwill change the goal to `2 + succ 1 = 4`. In contrast, `rw [two_eq_succ_one]`\nwill change the goal to `succ 1 + succ 1 = 4`.": "## 小结\n\n如果 `h : X = Y` 并且在目标中有多个 `X`,那么 `nth_rewrite 3 [h]` 将仅更改第三个 `X` 为 `Y`。\n\n## 示例\n\n如果目标是 `2 + 2 = 4`,那么 `nth_rewrite 2 [two_eq_succ_one]` 将目标更改为 `2 + succ 1 = 4`。相比之下,`rw [two_eq_succ_one]` 将目标更改为 `succ 1 + succ 1 = 4`。", diff --git a/.i18n/zh/Game.po b/.i18n/zh/Game.po index 9329bdbc..7e81b4e2 100644 --- a/.i18n/zh/Game.po +++ b/.i18n/zh/Game.po @@ -235,8 +235,8 @@ msgid "" "questions like this much easier, and goals like $20 + 20 ≠ 41$ feasible.\n" "Alternatively you can do more mathematics in Advanced Addition World, where " "we prove\n" -"the lemmas needed to get a working theory of inequalities. Click \"Leave " -"World\" and\n" +"the lemmas needed to get a working theory of inequalities. Click \"Home\" " +"and\n" "decide your route." msgstr "" "这是一个证明:\n" @@ -696,7 +696,7 @@ msgid "add_left_comm" msgstr "add_left_comm" #: Game.Levels.Tutorial.L03two_eq_ss0 -msgid "`one_eq_succ_zero` is a proof of `1 = succ 0`.\"" +msgid "`one_eq_succ_zero` is a proof of `1 = succ 0`." msgstr "`one_eq_succ_zero` 是 `1 = succ 0`的证明。" #: Game.Levels.Power.L02zero_pow_succ @@ -1190,7 +1190,7 @@ msgid "" "The next step in the development of order theory is to develop\n" "the theory of the interplay between `≤` and multiplication.\n" "If you've already done Multiplication World, you're now ready for\n" -"Advanced Multiplication World. Click on \"Leave World\" to access it." +"Advanced Multiplication World. Click on \"Home\" to access it." msgstr "" "很棒!\n" "\n" @@ -1508,15 +1508,15 @@ msgstr "" #: Game.Levels.Addition.L01zero_add msgid "" -"`zero_add x` is the proof of `0 + x = x`.\n" +"`zero_add n` is the proof of `0 + n = n`.\n" "\n" -"`zero_add` is a `simp` lemma, because replacing `0 + x` by `x`\n" +"`zero_add` is a `simp` lemma, because replacing `0 + n` by `n`\n" "is almost always what you want to do if you're simplifying an expression." msgstr "" -"`zero_add x` 是 `0 + x = x` 的证明。\n" +"`zero_add n` 是 `0 + n = n` 的证明。\n" "\n" "`zero_add` 是一个有 `simp` 标记的引理,因为如果你正在简化一个表达式,几乎总是" -"想要将 `0 + x` 替换为 `x`。" +"想要将 `0 + n` 替换为 `n`。" #: Game.Levels.AdvAddition.L03add_left_eq_self msgid "add_left_eq_self" @@ -2421,7 +2421,7 @@ msgid "" "If you can't remember the name of the proof of an equality, look it up in\n" "the list of lemmas on the right.\n" "\n" -"## Targetted usage\n" +"## Targeted usage\n" "\n" "If your goal is `b + c + a = b + (a + c)` and you want to rewrite `a + c`\n" "to `c + a`, then `rw [add_comm]` will not work because Lean finds another\n" @@ -3010,7 +3010,7 @@ msgid "" "move back into \"Typewriter mode\".\n" "\n" "You have finished tutorial world!\n" -"Click \"Leave World\" to go back to the\n" +"Click \"Home\" to go back to the\n" "overworld, and select Addition World, where you will learn\n" "about the `induction` tactic." msgstr "" @@ -3648,7 +3648,7 @@ msgid "" "```\n" "\n" "That's the end of Advanced Addition World! You'll need these theorems\n" -"for the next world, `≤` World. Click on \"Leave World\" to access it." +"for the next world, `≤` World. Click on \"Home\" to access it." msgstr "" "这个证明怎么样:\n" "\n" @@ -3833,7 +3833,7 @@ msgid "" msgstr "你能从这里开始吗?如果您需要提示,请点击 \"显示更多帮助!\"。" #: Game.Levels.Algorithm.L02add_algo1 -msgid "Finally use a targetted `add_comm` to switch `b` and `d`" +msgid "Finally use a targeted `add_comm` to switch `b` and `d`" msgstr "最后,使用有针对性的 `add_comm` 来交换 `b` 和 `d" #: Game.Levels.Multiplication.L07mul_add @@ -4179,7 +4179,7 @@ msgid "" "World. These tactics let you prove more facts about addition, such as\n" "how to deduce `a = 0` from `x + a = x`.\n" "\n" -"Click \"Leave World\" and make your choice." +"Click \"Home\" and make your choice." msgstr "" "你现在已经掌握了击败游戏最终 BOSS 所需的所有策略。\n" "你可以进入乘法世界,开始征服 BOSS 的冒险之旅。\n" @@ -4518,7 +4518,7 @@ msgid "" "* `add_succ a b : a + succ b = succ (a + b)`\n" "\n" "Other theorems about naturals, such as `zero_add a : 0 + a = a`, are proved\n" -"by induction using these two basic theorems.\"" +"by induction using these two basic theorems." msgstr "" "`Add a b`,符号为 `a + b`,是\n" "自然数之和。\n" @@ -4568,8 +4568,8 @@ msgid "Multiplication is commutative." msgstr "乘法是可交换的。" #: Game.Levels.Addition.L03add_comm -msgid "`add_comm x y` is a proof of `x + y = y + x`." -msgstr "`add_comm x y` 是 `x + y = y + x` 的证明。" +msgid "`add_comm a b` is a proof of `a + b = b + a`." +msgstr "`add_comm a b` 是 `a + b = b + a` 的证明。" #: Game.Levels.Implication.L02exact2 msgid "" @@ -5170,11 +5170,11 @@ msgstr "完成关卡!🎉" #: Game.Levels.Multiplication.L02zero_mul msgid "" -"`zero_mul x` is the proof that `0 * x = 0`.\n" +"`zero_mul m` is the proof that `0 * m = 0`.\n" "\n" "Note: `zero_mul` is a `simp` lemma." msgstr "" -"`zero_mul x` 是 `0 * x = 0` 的证明。\n" +"`zero_mul m` 是 `0 * m = 0` 的证明。\n" "\n" "注意:`zero_mul` 是一个 `simp` 引理。" @@ -5451,7 +5451,7 @@ msgid "" "You don't need induction. `add_assoc` moves brackets around,\n" "and `add_comm` moves variables around.\n" "\n" -"Remember that you can do more targetted rewrites by\n" +"Remember that you can do more targeted rewrites by\n" "adding explicit variables as inputs to theorems. For example `rw [add_comm " "b]`\n" "will only do rewrites of the form `b + ? = ? + b`, and `rw [add_comm b c]`\n" diff --git a/Game.lean b/Game.lean index 5389c712..d5cd8042 100644 --- a/Game.lean +++ b/Game.lean @@ -78,7 +78,7 @@ about the material. ## Resources * The [Lean Zulip chat](https://leanprover.zulipchat.com/) forum -* [Original Lean3 version](https://www.ma.imperial.ac.uk/~buzzard/xena/natural_number_game/) (no longer maintained) +* [Original Lean3 version](https://github.com/ImperialCollegeLondon/natural_number_game/) (no longer maintained) ## Problems? @@ -102,7 +102,7 @@ Alternatively, if you experience issues / bugs you can also open github issues: -- Dependency Implication → Power -- `Power` uses `≠` which is introduced in `Implication` /-! Information to be displayed on the servers landing page. -/ -Languages "en" "zh" "uk" "it" "fr" +Languages "en" "zh" "uk" "it" "fr" "pt-BR" CaptionShort "The classical introduction game for Lean." CaptionLong "In this game you recreate the natural numbers $\\mathbb{N}$ from the Peano axioms, learning the basics about theorem proving in Lean. diff --git a/Game/Levels/Addition/L01zero_add.lean b/Game/Levels/Addition/L01zero_add.lean index b462c67c..014c038b 100644 --- a/Game/Levels/Addition/L01zero_add.lean +++ b/Game/Levels/Addition/L01zero_add.lean @@ -34,9 +34,9 @@ back to \"Typewriter mode\" by clicking the `>_` button in the top right.) " /-- -`zero_add x` is the proof of `0 + x = x`. +`zero_add n` is the proof of `0 + n = n`. -`zero_add` is a `simp` lemma, because replacing `0 + x` by `x` +`zero_add` is a `simp` lemma, because replacing `0 + n` by `n` is almost always what you want to do if you're simplifying an expression. -/ TheoremDoc MyNat.zero_add as "zero_add" in "+" diff --git a/Game/Levels/Addition/L03add_comm.lean b/Game/Levels/Addition/L03add_comm.lean index 43e86ca9..452e24b4 100644 --- a/Game/Levels/Addition/L03add_comm.lean +++ b/Game/Levels/Addition/L03add_comm.lean @@ -15,7 +15,7 @@ Look in your inventory to see the proofs you have available. These should be enough. " -/-- `add_comm x y` is a proof of `x + y = y + x`. -/ +/-- `add_comm a b` is a proof of `a + b = b + a`. -/ TheoremDoc MyNat.add_comm as "add_comm" in "+" /-- On the set of natural numbers, addition is commutative. diff --git a/Game/Levels/Addition/L05add_right_comm.lean b/Game/Levels/Addition/L05add_right_comm.lean index a520787c..4e7fe621 100644 --- a/Game/Levels/Addition/L05add_right_comm.lean +++ b/Game/Levels/Addition/L05add_right_comm.lean @@ -17,7 +17,7 @@ Use associativity and commutativity to prove `add_right_comm`. You don't need induction. `add_assoc` moves brackets around, and `add_comm` moves variables around. -Remember that you can do more targetted rewrites by +Remember that you can do more targeted rewrites by adding explicit variables as inputs to theorems. For example `rw [add_comm b]` will only do rewrites of the form `b + ? = ? + b`, and `rw [add_comm b c]` will only do rewrites of the form `b + c = c + b`. @@ -47,5 +47,5 @@ Or you can go off the beaten track and learn some new tactics in Implication World. These tactics let you prove more facts about addition, such as how to deduce `a = 0` from `x + a = x`. -Click \"Leave World\" and make your choice. +Click \"Home\" and make your choice. " diff --git a/Game/Levels/AdvAddition/L06add_left_eq_zero.lean b/Game/Levels/AdvAddition/L06add_left_eq_zero.lean index e08b07d9..a43e0f08 100644 --- a/Game/Levels/AdvAddition/L06add_left_eq_zero.lean +++ b/Game/Levels/AdvAddition/L06add_left_eq_zero.lean @@ -29,5 +29,5 @@ exact add_right_eq_zero b a ``` That's the end of Advanced Addition World! You'll need these theorems -for the next world, `≤` World. Click on \"Leave World\" to access it. +for the next world, `≤` World. Click on \"Home\" to access it. " diff --git a/Game/Levels/Algorithm/L02add_algo1.lean b/Game/Levels/Algorithm/L02add_algo1.lean index 1261e2c9..569d4a0b 100644 --- a/Game/Levels/Algorithm/L02add_algo1.lean +++ b/Game/Levels/Algorithm/L02add_algo1.lean @@ -30,7 +30,7 @@ Statement (a b c d : ℕ) : a + b + (c + d) = a + c + d + b := by Hint "Now use `rw [add_left_comm b c]` to switch `b` and `c` on the left hand side." rw [add_left_comm b c] - Hint "Finally use a targetted `add_comm` to switch `b` and `d`" + Hint "Finally use a targeted `add_comm` to switch `b` and `d`." Hint (hidden := true) "`rw [add_comm b d]`." rw [add_comm b d] rfl diff --git a/Game/Levels/Implication/L02exact2.lean b/Game/Levels/Implication/L02exact2.lean index 960ee598..3a3b05ae 100644 --- a/Game/Levels/Implication/L02exact2.lean +++ b/Game/Levels/Implication/L02exact2.lean @@ -18,7 +18,7 @@ Statement (x y : ℕ) (h : 0 + x = 0 + y + 2) : x = y + 2 := by `rw [zero_add] at {h}` tries to fill in the arguments to `zero_add` (finding `{x}`) then it replaces all occurrences of - `0 + {x}` it finds. Therefor, it did not rewrite `0 + {y}`, yet." + `0 + {x}` it finds. Therefore, it did not rewrite `0 + {y}`, yet." rw [zero_add] at h Hint "Now you could finish with `rw [{h}]` then `rfl`, but `exact {h}` does it in one line." diff --git a/Game/Levels/Implication/L03apply.lean b/Game/Levels/Implication/L03apply.lean index babf4550..1e4d1d63 100644 --- a/Game/Levels/Implication/L03apply.lean +++ b/Game/Levels/Implication/L03apply.lean @@ -39,7 +39,7 @@ NewTactic apply Introduction " -In this level, the hypotheses `h2` is an *implication*. It says +In this level, the hypothesis `h2` is an *implication*. It says that *if* `x = 37` *then* `y = 42`. We can use this hypothesis with the `apply` tactic. Remember you can click on `apply` or any other tactic on the right to see a detailed explanation diff --git a/Game/Levels/Implication/L06intro.lean b/Game/Levels/Implication/L06intro.lean index 138d7a94..9d3339bc 100644 --- a/Game/Levels/Implication/L06intro.lean +++ b/Game/Levels/Implication/L06intro.lean @@ -27,8 +27,8 @@ NewTactic intro Introduction "We have seen how to `apply` theorems and assumptions of the form `P → Q`. But what if our *goal* is of the form `P → Q`? -To prove this goal, we need to know how to say \"let's assume `P` and deduce `Q`\" -in Lean. We do this with the `intro` tactic. +To prove this goal, we need to know how to say \"let's assume `P` and deduce `Q`\". +In Lean, we do this with the `intro` tactic. " /-- $x=37\implies x=37$. -/ diff --git a/Game/Levels/Implication/L11two_add_two_ne_five.lean b/Game/Levels/Implication/L11two_add_two_ne_five.lean index 4070e5e1..74a638b1 100644 --- a/Game/Levels/Implication/L11two_add_two_ne_five.lean +++ b/Game/Levels/Implication/L11two_add_two_ne_five.lean @@ -36,5 +36,5 @@ developed enough material to make it an adequate calculator. In Algorithm World, a more computer-sciency world, we will develop machinery which makes questions like this much easier, and goals like $20 + 20 ≠ 41$ feasible. Alternatively you can do more mathematics in Advanced Addition World, where we prove -the lemmas needed to get a working theory of inequalities. Click \"Leave World\" and +the lemmas needed to get a working theory of inequalities. Click \"Home\" and decide your route." diff --git a/Game/Levels/LessOrEqual/L11le_two.lean b/Game/Levels/LessOrEqual/L11le_two.lean index 175fea36..68f535e9 100644 --- a/Game/Levels/LessOrEqual/L11le_two.lean +++ b/Game/Levels/LessOrEqual/L11le_two.lean @@ -44,5 +44,5 @@ Nice! The next step in the development of order theory is to develop the theory of the interplay between `≤` and multiplication. If you've already done Multiplication World, you're now ready for -Advanced Multiplication World. Click on \"Leave World\" to access it. +Advanced Multiplication World. Click on \"Home\" to access it. " diff --git a/Game/Levels/Multiplication/L02zero_mul.lean b/Game/Levels/Multiplication/L02zero_mul.lean index 56f82008..2b33f721 100644 --- a/Game/Levels/Multiplication/L02zero_mul.lean +++ b/Game/Levels/Multiplication/L02zero_mul.lean @@ -16,7 +16,7 @@ start with this. " /-- -`zero_mul x` is the proof that `0 * x = 0`. +`zero_mul m` is the proof that `0 * m = 0`. Note: `zero_mul` is a `simp` lemma. -/ diff --git a/Game/Levels/OldFunction/Level_1.lean b/Game/Levels/OldFunction/Level_1.lean index 450a181c..e3af5398 100644 --- a/Game/Levels/OldFunction/Level_1.lean +++ b/Game/Levels/OldFunction/Level_1.lean @@ -53,7 +53,7 @@ Statement Note that while in mathematics you might write $h(p)$, in Lean you always avoid brackets for function application: `h p`. Brackets are only used for grouping elements, for - example for repeated funciton application, you could write `g (h p)`. + example for repeated function application, you could write `g (h p)`. " Hint (hidden := true) " **Important note**: Note that `exact h P,` won't work (with a capital $P$); diff --git a/Game/Levels/OldProposition/FuncProgram.lean b/Game/Levels/OldProposition/FuncProgram.lean index 79bf91b3..dd396910 100644 --- a/Game/Levels/OldProposition/FuncProgram.lean +++ b/Game/Levels/OldProposition/FuncProgram.lean @@ -76,7 +76,7 @@ and this proof of `succ_inj` will only use `pred` on positive naturals, just like today's cultured mathematician never divides by zero. -We need to learn how to deal wiht a goal of the form `P → Q` +We need to learn how to deal with a goal of the form `P → Q` -/ @@ -128,7 +128,7 @@ unsafe def collatz : ℕ → ℕ -- sorry Here is a crank proof I was sent of the 3n+1 -problem. Explanaiton of problem. Proof: By induction. +problem. Explanation of problem. Proof: By induction. Define f(1)=stop. Got to prove that for all n, it terminates. diff --git a/Game/Levels/OldProposition/Level_8.lean b/Game/Levels/OldProposition/Level_8.lean index b276bdb0..292bd816 100644 --- a/Game/Levels/OldProposition/Level_8.lean +++ b/Game/Levels/OldProposition/Level_8.lean @@ -42,7 +42,7 @@ Statement -- defeq option in hints would help Hint "Now you have to prove `False`. I guess that means you must be proving something by contradiction. Or are you?" - Hint (hidden := true) "If you `apply {h}` the `False` magically dissappears again. Can you make + Hint (hidden := true) "If you `apply {h}` the `False` magically disappears again. Can you make mathematical sense of these two steps?" apply h apply f @@ -57,7 +57,7 @@ Statement Hint "If you're stuck, you could do `rw [Not] at {h}`. Maybe that helps." Branch rw [Not] at h - Hint "If you `apply {h}` the `False` magically dissappears again. Can you make + Hint "If you `apply {h}` the `False` magically disappears again. Can you make mathematical sense of these two steps?" apply h apply f diff --git a/Game/Levels/Tutorial/L02rw.lean b/Game/Levels/Tutorial/L02rw.lean index 1dbd655e..6de7c82c 100644 --- a/Game/Levels/Tutorial/L02rw.lean +++ b/Game/Levels/Tutorial/L02rw.lean @@ -94,7 +94,7 @@ Exercise: think about why `rw [add_zero]` changes the term If you can't remember the name of the proof of an equality, look it up in the list of lemmas on the right. -## Targetted usage +## Targeted usage If your goal is `b + c + a = b + (a + c)` and you want to rewrite `a + c` to `c + a`, then `rw [add_comm]` will not work because Lean finds another diff --git a/Game/Levels/Tutorial/L03two_eq_ss0.lean b/Game/Levels/Tutorial/L03two_eq_ss0.lean index fcbb33a7..c2b51cb3 100644 --- a/Game/Levels/Tutorial/L03two_eq_ss0.lean +++ b/Game/Levels/Tutorial/L03two_eq_ss0.lean @@ -24,7 +24,7 @@ never leak into the natural number game.* DefinitionDoc MyNat as "ℕ" -/-- `one_eq_succ_zero` is a proof of `1 = succ 0`." -/ +/-- `one_eq_succ_zero` is a proof of `1 = succ 0`. -/ TheoremDoc MyNat.one_eq_succ_zero as "one_eq_succ_zero" in "012" /-- `two_eq_succ_one` is a proof of `2 = succ 1`. -/ diff --git a/Game/Levels/Tutorial/L05add_zero.lean b/Game/Levels/Tutorial/L05add_zero.lean index 1d373ea4..94831abe 100644 --- a/Game/Levels/Tutorial/L05add_zero.lean +++ b/Game/Levels/Tutorial/L05add_zero.lean @@ -16,7 +16,7 @@ via the following two hypotheses: * `add_succ a b : a + succ b = succ (a + b)` Other theorems about naturals, such as `zero_add a : 0 + a = a`, are proved -by induction using these two basic theorems." +by induction using these two basic theorems. -/ DefinitionDoc Add as "+" diff --git a/Game/Levels/Tutorial/L08twoaddtwo.lean b/Game/Levels/Tutorial/L08twoaddtwo.lean index 85880bd6..140113e4 100644 --- a/Game/Levels/Tutorial/L08twoaddtwo.lean +++ b/Game/Levels/Tutorial/L08twoaddtwo.lean @@ -54,7 +54,7 @@ around to investigate. When you've finished, click the `>_` button in the top ri move back into \"Typewriter mode\". You have finished tutorial world! -Click \"Leave World\" to go back to the +Click \"Home\" to go back to the overworld, and select Addition World, where you will learn about the `induction` tactic. " diff --git a/Game/Tactic/Induction.lean b/Game/Tactic/Induction.lean index c90faa24..c89265d5 100644 --- a/Game/Tactic/Induction.lean +++ b/Game/Tactic/Induction.lean @@ -18,7 +18,7 @@ This is mainly copied and modified from the mathlib-tactic `induction'`. -/ /-- -Custom induction principial for the tactics `induction`. +Custom induction principle for the tactics `induction`. Used to show `0` instead of `MyNat.zero` in the base case. -/ def rec' {P : ℕ → Prop} (zero : P 0) diff --git a/README.md b/README.md index bf6d97fc..ab3f56bd 100644 --- a/README.md +++ b/README.md @@ -4,14 +4,14 @@ This is the lean4 version of the classical *Natural Number Game*. It uses the [Lean4 Game Engine](https://github.com/leanprover-community/lean4game) and is running live at [adam.math.hhu.de](https://adam.math.hhu.de). -The game was initially designed for lean3 and has been adapted for lean4. [See lean3 version](https://www.ma.imperial.ac.uk/~buzzard/xena/natural_number_game/). +The game was initially designed for lean3 and has been adapted for lean4. [See lean3 version](https://github.com/ImperialCollegeLondon/natural_number_game/). ## Getting Started You can develop the game as any lean project and use `lake build` to build it. Moreover, there are multiple ways to run the game while developing it, which are described in -[Running Games Locally](https://github.com/leanprover-community/lean4game/blob/main/doc/running_locally.md) +[Running Games Locally](https://github.com/leanprover-community/lean4game/blob/main/doc/running_locally.md). ## Contributing