mirror of
https://github.com/kennethreitz/dive-into-python3.git
synced 2026-06-05 23:10:17 +00:00
dropped /td, /th, /tr end elements
This commit is contained in:
@@ -93,9 +93,9 @@ if __name__ == "__main__":
|
||||
<p>So Python is both <em>dynamically typed</em> (because it doesn't use explicit datatype declarations) and <em>strongly typed</em> (because once a variable has a datatype, it actually matters).
|
||||
<p>If you have experience in other programming languages, this table may help you visualize how Python compares to them:
|
||||
<table>
|
||||
<tr><th></th><th>Statically typed</th><th>Dynamically typed</th></tr>
|
||||
<tr><th>Weakly typed</th><td>C, Objective-C</td><td>JavaScript, Perl 5, <abbr>PHP</abbr></td></tr>
|
||||
<tr><th>Strongly typed</th><td>Pascal, Java</td><td>Python, Ruby</td></tr>
|
||||
<tr><th><th>Statically typed<th>Dynamically typed
|
||||
<tr><th>Weakly typed<td>C, Objective-C<td>JavaScript, Perl 5, <abbr>PHP</abbr>
|
||||
<tr><th>Strongly typed<td>Pascal, Java<td>Python, Ruby
|
||||
</table>
|
||||
<h2 id=readability>Writing Readable Code</h2>
|
||||
<p>I won't bore you with a long finger-wagging speech about the importance of documenting your code. Just know that code is written once but read many times, and the most important audience for your code is yourself, six months after writing it (i.e. after you've forgotten everything but need to fix something). Python makes it easy to write readable code, so take advantage of it. You'll thank me in six months.
|
||||
|
||||
Reference in New Issue
Block a user