mirror of
https://github.com/python/cpython.git
synced 2025-08-14 22:01:08 +00:00

svn+ssh://pythondev@svn.python.org/python/trunk ........ r70642 | georg.brandl | 2009-03-28 01:48:48 +0100 (Sa, 28 Mär 2009) | 1 line Fix typo. ........ r70648 | georg.brandl | 2009-03-28 20:10:37 +0100 (Sa, 28 Mär 2009) | 1 line #5324: document __subclasses__(). ........ r70656 | georg.brandl | 2009-03-28 20:33:33 +0100 (Sa, 28 Mär 2009) | 2 lines Add a script to fixup rst files if the pre-commit hook rejects them. ........ r70661 | georg.brandl | 2009-03-28 20:57:36 +0100 (Sa, 28 Mär 2009) | 2 lines Add section numbering to some of the larger subdocuments. ........ r70765 | georg.brandl | 2009-03-31 00:09:34 +0200 (Di, 31 Mär 2009) | 1 line #5199: make warning about vars() assignment more visible. ........ r70773 | georg.brandl | 2009-03-31 00:43:00 +0200 (Di, 31 Mär 2009) | 1 line #5039: make it clear that the impl. note refers to CPython. ........ r70789 | georg.brandl | 2009-03-31 03:25:15 +0200 (Di, 31 Mär 2009) | 1 line Fix a wrong struct field assignment (docstring as closure). ........ r70824 | georg.brandl | 2009-03-31 17:43:20 +0200 (Di, 31 Mär 2009) | 1 line #5519: remove reference to Kodos, which seems dead. ........ r70825 | georg.brandl | 2009-03-31 17:46:30 +0200 (Di, 31 Mär 2009) | 1 line #5566: fix versionadded from PyLong ssize_t functions. ........ r70828 | georg.brandl | 2009-03-31 17:50:16 +0200 (Di, 31 Mär 2009) | 1 line #5581: fget argument of abstractproperty is optional as well. ........ r70830 | georg.brandl | 2009-03-31 18:11:45 +0200 (Di, 31 Mär 2009) | 1 line #5529: backport new docs of import semantics written by Brett to 2.x. ........ r70832 | georg.brandl | 2009-03-31 18:31:11 +0200 (Di, 31 Mär 2009) | 1 line #1386675: specify WindowsError as the exception, because it has a winerror attribute that EnvironmentError doesnt have. ........ r70836 | georg.brandl | 2009-03-31 18:50:25 +0200 (Di, 31 Mär 2009) | 1 line #5417: replace references to undocumented functions by ones to documented functions. ........ r70838 | georg.brandl | 2009-03-31 18:54:38 +0200 (Di, 31 Mär 2009) | 1 line #992207: document that the parser only accepts \\n newlines. ........ r70842 | georg.brandl | 2009-03-31 19:13:06 +0200 (Di, 31 Mär 2009) | 1 line #970783: document PyObject_Generic[GS]etAttr. ........ r70851 | georg.brandl | 2009-03-31 20:26:55 +0200 (Di, 31 Mär 2009) | 1 line #837577: note cryptic return value of spawn*e on invalid env dicts. ........ r70855 | georg.brandl | 2009-03-31 20:30:37 +0200 (Di, 31 Mär 2009) | 1 line #5245: note that PyRun_SimpleString doesnt return on SystemExit. ........ r70857 | georg.brandl | 2009-03-31 20:33:10 +0200 (Di, 31 Mär 2009) | 1 line #5227: note that Py_Main doesnt return on SystemExit. ........ r70858 | georg.brandl | 2009-03-31 20:38:56 +0200 (Di, 31 Mär 2009) | 1 line #5241: document missing U in regex howto. ........
62 lines
2.4 KiB
ReStructuredText
62 lines
2.4 KiB
ReStructuredText
.. _tutorial-index:
|
|
|
|
######################
|
|
The Python Tutorial
|
|
######################
|
|
|
|
:Release: |version|
|
|
:Date: |today|
|
|
|
|
Python is an easy to learn, powerful programming language. It has efficient
|
|
high-level data structures and a simple but effective approach to
|
|
object-oriented programming. Python's elegant syntax and dynamic typing,
|
|
together with its interpreted nature, make it an ideal language for scripting
|
|
and rapid application development in many areas on most platforms.
|
|
|
|
The Python interpreter and the extensive standard library are freely available
|
|
in source or binary form for all major platforms from the Python Web site,
|
|
http://www.python.org/, and may be freely distributed. The same site also
|
|
contains distributions of and pointers to many free third party Python modules,
|
|
programs and tools, and additional documentation.
|
|
|
|
The Python interpreter is easily extended with new functions and data types
|
|
implemented in C or C++ (or other languages callable from C). Python is also
|
|
suitable as an extension language for customizable applications.
|
|
|
|
This tutorial introduces the reader informally to the basic concepts and
|
|
features of the Python language and system. It helps to have a Python
|
|
interpreter handy for hands-on experience, but all examples are self-contained,
|
|
so the tutorial can be read off-line as well.
|
|
|
|
For a description of standard objects and modules, see the Python Library
|
|
Reference document. The Python Reference Manual gives a more formal definition
|
|
of the language. To write extensions in C or C++, read Extending and Embedding
|
|
the Python Interpreter and Python/C API Reference. There are also several books
|
|
covering Python in depth.
|
|
|
|
This tutorial does not attempt to be comprehensive and cover every single
|
|
feature, or even every commonly used feature. Instead, it introduces many of
|
|
Python's most noteworthy features, and will give you a good idea of the
|
|
language's flavor and style. After reading it, you will be able to read and
|
|
write Python modules and programs, and you will be ready to learn more about the
|
|
various Python library modules described in the Python Library Reference.
|
|
|
|
The :ref:`glossary` is also worth going through.
|
|
|
|
.. toctree::
|
|
:numbered:
|
|
|
|
appetite.rst
|
|
interpreter.rst
|
|
introduction.rst
|
|
controlflow.rst
|
|
datastructures.rst
|
|
modules.rst
|
|
inputoutput.rst
|
|
errors.rst
|
|
classes.rst
|
|
stdlib.rst
|
|
stdlib2.rst
|
|
whatnow.rst
|
|
interactive.rst
|
|
floatingpoint.rst
|