12.07.2015 Views

Think Python - Denison University

Think Python - Denison University

Think Python - Denison University

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

212 Indexcoordinate, 184set,129anagram, 123, 140set membership, 104setdefault method, 109sexagesimal, 156shallow copy, 150, 151shape, 123shape error,122shell,140shelve module, 140, 144shuffle function, 174SimpleTurtleWorld class,186sinefunction, 18singleton, 108, 113, 115slice,79copy, 74, 92list,92string,73tuple, 116update, 92sliceoperator, 73, 79, 92, 98, 116sortmethod, 92, 99, 121, 174sortedfunction, 122source code, 2, 7special case, 85, 86, 155special valueFalse, 39None, 24, 52, 60, 93, 94True, 39splitmethod, 95, 116sqrt,53sqrtfunction, 18square root, 66squiggly bracket, 103stack diagram, 23, 26, 36, 43, 56, 60, 97state diagram, 10, 15, 63, 78, 90, 96, 97, 108,120, 146, 148, 150, 153, 171statement, 12, 15assert,157assignment, 10, 63break, 65compound, 40conditional, 40, 47, 55for,30, 72, 91global, 110if,40import, 26, 29, 142pass, 41print,6, 8, 163, 199raise, 107, 157return, 43, 51, 201try, 138while, 64step size,79strfunction, 18str method, 163, 172string, 9, 15, 95, 122accumulator, 173comparison, 77empty, 95immutable, 74method, 75multiline, 35, 196operation, 14slice, 73triple-quoted, 35stringmethod, 79stringmodule, 125stringrepresentation, 142, 163stringtype, 9stripmethod, 82, 125structshape module, 122structure, 5subclass, 174subject, 160, 167, 187subtractiondictionary, 129withborrowing, 68subtraction withborrowing, 157suffix, 131suit,169sum function, 118superclass, 174superstitious debugging, 201SVG, 193Swampy, 29, 81, 151, 179, 181swap pattern, 116syntax, 3, 7, 159, 196syntax error,3, 7, 15, 195SyntaxError, 19Tagger, 179temporary variable, 51, 60, 201test case, minimal, 199testingand absence of bugs, 85incremental development, 52interactive mode, 2ishard, 85

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!