Think Python

Think Python  (English, Undefined, Downey Allen)

Price: Not Available
Currently Unavailable
Author
Read More
Highlights
  • Language: English
  • Binding: Undefined
  • Publisher: Packt
  • Genre: Computers
  • ISBN: 9789350238639, 9789350238639
Description

If you want to learn how to program, working with Python is an excellent way to start. This hands-on guide takes you through the language one step at a time, beginning with basic programming concepts before moving on to functions, recursion, data structures, and object-oriented design.

Through exercises in each chapter, you’ll try out programming concepts as you learn them. Think Python is ideal for students at the high school or college level, as well as self-learners, home-schooled students, and professionals who need to learn programming basics.

  •     Start with the basics, including language syntax and semantics
  •     Get a clear definition of each programming concept
  •     Learn values, variables, statements, functions, and data structures in a logical progression
  •     Discover how to work with files and databases
  •     Understand objects, methods, and object-oriented programming
  •     Use debugging techniques to fix syntax, runtime, and semantic errors
  •     Explore interface design, data structures, and GUI-based programs through case studies

About The Author
Allen Downey is an Associate Professor of Computer Science at the Olin College of Engineering. He has taught computer science at Wellesley College, Colby College and U.C. Berkeley. He has a Ph.D. in Computer Science from U.C. Berkeley and Master’s and Bachelor’s degrees from MIT.

Table of Contents

Chapter 1 The Way of the Program

  •     The Python Programming Language
  •     What Is a Program?
  •     What Is Debugging?
  •     Syntax Errors
  •     Runtime Errors
  •     Semantic Errors
  •     Experimental Debugging
  •     Formal and Natural Languages
  •     The First Program
  •     Debugging
  •     Glossary
  •     Exercises

Chapter 2 Variables, Expressions, and Statements

  •     Values and Types
  •     Variables
  •     Variable Names and Keywords
  •     Operators and Operands
  •     Expressions and Statements
  •     Interactive Mode and Script Mode
  •     Order of Operations
  •     String Operations
  •     Comments
  •     Debugging
  •     Glossary
  •     Exercises

Chapter 3 Functions

  •     Function Calls
  •     Type Conversion Functions
  •     Math Functions
  •     Composition
  •     Adding New Functions
  •     Definitions and Uses
  •     Flow of Execution
  •     Parameters and Arguments
  •     Variables and Parameters Are Local
  •     Stack Diagrams
  •     Fruitful Functions and Void Functions
  •     Why Functions?
  •     Importing with from
  •     Debugging
  •     Glossary
  •     Exercises

Chapter 4 Case Study: Interface Design

  •     TurtleWorld
  •     Simple Repetition
  •     Exercises
  •     Encapsulation
  •     Generalization
  •     Interface Design
  •     Refactoring
  •     A Development Plan
  •     Docstring
  •     Debugging
  •     Glossary
  •     Exercises

Chapter 5 Conditionals and Recursion

  •     Modulus Operator
  •     Boolean Expressions
  •     Logical Operators
  •     Conditional Execution
  •     Alternative Execution
  •     Chained Conditionals
  •     Nested Conditionals
  •     Recursion
  •     Stack Diagrams for Recursive Functions
  •     Infinite Recursion
  •     Keyboard Input
  •     Debugging
  •     Glossary
  •     Exercises

Chapter 6 Fruitful Functions

  •     Return Values
  •     Incremental Development
  •     Composition
  •     Boolean Functions
  •     More Recursion
  •     Leap of Faith
  •     One More Example
  •     Checking Types
  •     Debugging
  •     Glossary
  •     Exercises

Chapter 7 Iteration

  •     Multiple Assignment
  •     Updating Variables
  •     The while Statement
  •     break
  •     Square Roots
  •     Algorithms
  •     Debugging
  •     Glossary
  •     Exercises

Chapter 8 Strings

  •     A String Is a Sequence
  •     len
  •     Traversal with a for Loop
  •     String Slices
  •     Strings Are Immutable
  •     Searching
  •     Looping and Counting
  •     String Methods
  •     The in Operator
  •     String Comparison
  •     Debugging
  •     Glossary
  •     Exercises

Chapter 9 Case Study: Word Play

  •     Reading Word Lists
  •     Exercises
  •     Search
  •     Looping with Indices
  •     Debugging
  •     Glossary
  •     Exercises

Chapter 10 Lists

  •     A List Is a Sequence
  •     Lists Are Mutable
  •     Traversing a List
  •     List Operations
  •     List Slices
  •     List Methods
  •     Map, Filter, and Reduce
  •     Deleting Elements
  •     Lists and Strings
  •     Objects and Values
  •     Aliasing
  •     List Arguments
  •     Debugging
  •     Glossary
  •     Exercises

Chapter 11 Dictionaries

  •     Dictionary as a Set of Counters
  •     Looping and Dictionaries
  •     Reverse Lookup
  •     Dictionaries and Lists
  •     Memos
  •     Global Variables
  •     Long Integers
  •     Debugging
  •     Glossary
  •     Exercises

Chapter 12 Tuples

  •     Tuples Are Immutable
  •     Tuple Assignment
  •     Tuples as Return Values
  •     Variable-Length Argument Tuples
  •     Lists and Tuples
  •     Dictionaries and Tuples
  •     Comparing Tuples
  •     Sequences of Sequences
  •     Debugging
  •     Glossary
  •     Exercises

Chapter 13 Case Study: Data Structure Selection

  •     Word Frequency Analysis
  •     Random Numbers
  •     Word Histogram
  •     Most Common Words
  •     Optional Parameters
  •     Dictionary Subtraction
  •     Random Words
  •     Markov Analysis
  •     Data Structures
  •     Debugging
  •     Glossary
  •     Exercises

Chapter 14 Files

  •     Persistence
  •     Reading and Writing
  •     Format Operator
  •     Filenames and Paths
  •     Catching Exceptions
  •     Databases
  •     Pickling
  •     Pipes
  •     Writing Modules
  •     Debugging
  •     Glossary
  •     Exercises

Chapter 15 Classes and Objects

  •     User-Defined Types
  •     Attributes
  •     Rectangles
  •     Instances as Return Values
  •     Objects Are Mutable
  •     Copying
  •     Debugging
  •     Glossary
  •     Exercises

Chapter 16 Classes and Functions

  •     Time
  •     Pure Functions
  •     Modifiers
  •     Prototyping Versus Planning
  •     Debugging
  •     Glossary
  •     Exercises

Chapter 17 Classes and Methods

  •     Object-Oriented Features
  •     Printing Objects
  •     Another Example
  •     A More Complicated Example
  •     The init Method
  •     The __str__ Method
  •     Operator Overloading
  •     Type-Based Dispatch
  •     Polymorphism
  •     Debugging
  •     Interface and Implementation
  •     Glossary
  •     Exercises

Chapter 18 Inheritance

  •     Card Objects
  •     Class Attributes
  •     Comparing Cards
  •     Decks
  •     Printing the Deck
  •     Add, Remove, Shuffle, and Sort
  •     Inheritance
  •     Class Diagrams
  •     Debugging
  •     Data Encapsulation
  •     Glossary
  •     Exercises

Chapter 19 Case Study: Tkinter

  •     GUI
  •     Buttons and Callbacks
  •     Canvas Widgets
  •     Coordinate Sequences
  •     More Widgets
  •     Packing Widgets
  •     Menus and Callables
  •     Binding
  •     Debugging
  •     Glossary
  •     Exercises

Appendix Debugging

  •     Syntax Errors
  •     Runtime Errors
  •     Semantic Errors

Appendix Analysis of Algorithms

  •     Order of Growth
  •     Analysis of Basic Python Operations
  •     Analysis of Search Algorithms
  •     Hashtables

Appendix Lumpy

  •     State Diagram
  •     Stack Diagram
  •     Object Diagrams
  •     Function and Class Objects
  •     Class Diagrams

Colophon

Read More
Specifications
Imprint
  • Packt
Ratings & Reviews
4.3
201 Ratings &
19 Reviews
  • 5
  • 4
  • 3
  • 2
  • 1
  • 109
  • 65
  • 15
  • 5
  • 7
5

Great Book

`This is a awesome book to start with python.Although the book is mostly for folks who are starting off with programming but it works great even with those who already have good programming knowledge with other languages.

The book is very interactive and provides interesting code examples and exerciese that we can try out.It also has a supporting website where the author has solutions for codes and some custom libraries that are used in the course of the exercises.
READ MORE

Madhao Wagh

Certified Buyer, Nagpur

Apr, 2014

10
3
Report Abuse
5

Excellent Book

This book is excellent for people who have never programmed before and even for advanced programmers.Mr Downey's explanations are very clear and lucid and the exercises are engaging.
Python is a very good language for beginners as it is both simple,clear and powerful.
Think Python as a textbook is a clear personification of Python itself.
READ MORE

Nishant

Jul, 2013

1
0
Report Abuse
5

Classy product

One of the finest Python programming book. The way topics are dealt are absolutely good. Many easy analogies are given to support the idea being discussed. The level starts from basic and goes into object oriented approach using Python. Overall I recommend the book.
READ MORE

Shashank Sathish

Certified Buyer, Chennai

Sep, 2017

0
0
Report Abuse
5

Good reference book

Describes language syntax adequately. Is aimed at a beginner, who knows at least one other programming language. Also acts as a basic handbook of simple features of the language. I read it twice in a week and outgrew it in a fortnight. Think of it as a primer before you move on to the official Python documentation.
READ MORE

Shaji DJ

Certified Buyer, Jammu

Dec, 2014

2
1
Report Abuse
5

Super!

Mind blowing book
READ MORE

Prashant Chetry

Certified Buyer, Guwahati

Oct, 2017

1
0
Report Abuse
5

Great book for beginners in programming.

This is a great book for an introduction to Computer Science and Programming. Chapters are short and language is simple. The entire book can be completed in about 15-20 days. What i really like about this book is the importance the author lays upon debugging. At the end of every chapter there's a section for debugging.
READ MORE

Himanshu Das

Certified Buyer, Guwahati

Apr, 2013

3
3
Report Abuse
4

Worth the money

Good book on python not very voluminous.
READ MORE

Ratna Pathak

Certified Buyer, Patna

May, 2017

0
0
Report Abuse
4

Value-for-money

Good...
READ MORE

Argha Sarkar

Certified Buyer, Khardaha

May, 2017

0
0
Report Abuse
5

Great product

Nice book
READ MORE

Kiran Sawant

Certified Buyer, Mumbai

May, 2017

0
0
Report Abuse
4

Good book for beginners

This is a good book for who are new to python. This book covers all the basic concepts.
READ MORE

Himanshu Anand

Certified Buyer, Bokaro

Mar, 2017

0
0
Report Abuse
+
All 19 reviews
Have doubts regarding this product?
Safe and Secure Payments.Easy returns.100% Authentic products.
You might be interested in
Psychology Books
Min. 50% Off
Shop Now
Finance And Accounting Books
Min. 50% Off
Shop Now
Other Self-Help Books
Min. 50% Off
Shop Now
Mathematics And Science Books
Min. 50% Off
Shop Now
Back to top