mirror of
https://github.com/kennethreitz/dive-into-python3.git
synced 2026-06-05 15:00:18 +00:00
consistent capitalization
This commit is contained in:
@@ -34,7 +34,7 @@ E = 1
|
||||
S = 2
|
||||
T = 0</code></pre>
|
||||
|
||||
<p>This kind of puzzle is called <i>cryptarithm</i> or <i>alphametics</i>. The letters spell out actual words, but if you replace each letter with a digit from <code>0–9</code>, it also “spells” an arithmetic equation. The trick is to figure out which letter maps to each digit. All the occurrences of each letter must map to the same digit, no digit can be repeated, and no “word” can start with the digit <code>0</code>.
|
||||
<p>Puzzles like this are called <i>cryptarithms</i> or <i>alphametics</i>. The letters spell out actual words, but if you replace each letter with a digit from <code>0–9</code>, it also “spells” an arithmetic equation. The trick is to figure out which letter maps to each digit. All the occurrences of each letter must map to the same digit, no digit can be repeated, and no “word” can start with the digit <code>0</code>.
|
||||
|
||||
<p>The most well-known alphametic puzzle is <code>SEND + MORE = MONEY</code>.
|
||||
|
||||
|
||||
@@ -570,7 +570,7 @@ rules = LazyRules()</code></pre>
|
||||
<li><a href=http://www.python.org/dev/peps/pep-0255/>PEP 255: Simple Generators</a>
|
||||
</ul>
|
||||
|
||||
<p class=nav><a rel=prev href=regular-expressions.html title="Back to “Regular Expressions”"><span>☜</a> <a rel=next href=advanced-iterators.html title="Onward to “Advanced Iterators”"><span>☞</span></a>
|
||||
<p class=nav><a rel=prev href=regular-expressions.html title="back to “Regular Expressions”"><span>☜</a> <a rel=next href=advanced-iterators.html title="onward to “Advanced Iterators”"><span>☞</span></a>
|
||||
|
||||
<p class=c>© 2001–9 <a href=about.html>Mark Pilgrim</a>
|
||||
<script src=jquery.js></script>
|
||||
|
||||
@@ -453,7 +453,7 @@ KeyError: 'db.diveintopython3.org'</samp></pre>
|
||||
<li><a href="http://www.python.org/dev/peps/pep-0237/"><abbr>PEP</abbr> 237: Unifying Long Integers and Integers</a>
|
||||
<li><a href="http://www.python.org/dev/peps/pep-0238/"><abbr>PEP</abbr> 238: Changing the Division Operator</a>
|
||||
</ul>
|
||||
<p class=nav><a rel=prev href=your-first-python-program.html title="Back to “Your First Python Program”"><span>☜</a> <a rel=next href=strings.html title="Onward to “Strings”"><span>☞</span></a>
|
||||
<p class=nav><a rel=prev href=your-first-python-program.html title="back to “Your First Python Program”"><span>☜</a> <a rel=next href=strings.html title="onward to “Strings”"><span>☞</span></a>
|
||||
<p class=c>© 2001–9 <a href=about.html>Mark Pilgrim</a>
|
||||
<script src=jquery.js></script>
|
||||
<script src=dip3.js></script>
|
||||
|
||||
@@ -1157,7 +1157,7 @@ do_stuff(a_list)</code></pre></td>
|
||||
do_stuff(a_list)</code></pre></td></tr>
|
||||
</table>
|
||||
<p>FIXME: once the rest of the book is written, this appendix should contain copious links back to any chapter or section that touches on these features.
|
||||
<p class=nav><a rel=prev href=case-study-porting-chardet-to-python-3.html title="Back to “Case Study: Porting chardet to Python 3”"><span>☜</a> <a rel=next class=todo><span>☞</span></a>
|
||||
<p class=nav><a rel=prev href=case-study-porting-chardet-to-python-3.html title="back to “Case Study: Porting chardet to Python 3”"><span>☜</a> <a rel=next class=todo><span>☞</span></a>
|
||||
<p class=c>© 2001–9 <a href=about.html>Mark Pilgrim</a>
|
||||
<script src=jquery.js></script>
|
||||
<script src=dip3.js></script>
|
||||
|
||||
@@ -417,7 +417,7 @@ body{counter-reset:h1 4}
|
||||
<li><code>(x)</code> in general is a <em>remembered group</em>. You can get the value of what matched by using the <code>groups()</code> method of the object returned by <code>re.search</code>.
|
||||
</ul>
|
||||
<p>Regular expressions are extremely powerful, but they are not the correct solution for every problem. You should learn enough about them to know when they are appropriate, when they will solve your problems, and when they will cause more problems than they solve.
|
||||
<p class=nav><a rel=prev href=strings.html title="Back to “Strings”"><span>☜</a> <a rel=next href=iterators-and-generators.html title="Onward to “Iterators & Generators”"><span>☞</span></a>
|
||||
<p class=nav><a rel=prev href=strings.html title="back to “Strings”"><span>☜</a> <a rel=next href=iterators-and-generators.html title="onward to “Iterators & Generators”"><span>☞</span></a>
|
||||
<p class=c>© 2001–9 <a href=about.html>Mark Pilgrim</a>
|
||||
<script src=jquery.js></script>
|
||||
<script src=dip3.js></script>
|
||||
|
||||
+1
-1
@@ -420,7 +420,7 @@ FIXME: move this to the intro of the upcoming files chapter?
|
||||
<li><a href="http://www.python.org/dev/peps/pep-3101/"><abbr>PEP</abbr> 3101: Advanced String Formatting</a>
|
||||
</ul>
|
||||
|
||||
<p class=nav><a rel=prev href=native-datatypes.html title="Back to “Native Datatypes”"><span>☜</a> <a rel=next href=regular-expressions.html title="Onward to “Regular Expressions”"><span>☞</span></a>
|
||||
<p class=nav><a rel=prev href=native-datatypes.html title="back to “Native Datatypes”"><span>☜</a> <a rel=next href=regular-expressions.html title="onward to “Regular Expressions”"><span>☞</span></a>
|
||||
|
||||
<p class=c>© 2001–9 <a href=about.html>Mark Pilgrim</a>
|
||||
<script src=jquery.js></script>
|
||||
|
||||
@@ -223,7 +223,7 @@ if __name__ == "__main__":
|
||||
<li><a href=http://www.python.org/dev/peps/pep-0008/>PEP 8: Style Guide for Python Code</a> discusses good indentation style.
|
||||
<li><a href=http://docs.python.org/3.0/reference/><cite>Python Reference Manual</cite></a> explains what it means to say that <a href=http://docs.python.org/3.0/reference/datamodel.html#objects-values-and-types>everything in Python is an object</a>, because some people are pedantic and like to discuss that sort of thing at great length.
|
||||
</ul>
|
||||
<p class=nav><a rel=prev class=todo><span>☜</a> <a rel=next href=native-datatypes.html title="Onward to “Native Datatypes”"><span>☞</span></a>
|
||||
<p class=nav><a rel=prev class=todo><span>☜</a> <a rel=next href=native-datatypes.html title="onward to “Native Datatypes”"><span>☞</span></a>
|
||||
<p class=c>© 2001–9 <a href=about.html>Mark Pilgrim</a>
|
||||
<script src=jquery.js></script>
|
||||
<script src=dip3.js></script>
|
||||
|
||||
Reference in New Issue
Block a user