diff options
author | Ezio Melotti <ezio.melotti@gmail.com> | 2014-02-24 18:58:31 (GMT) |
---|---|---|
committer | Ezio Melotti <ezio.melotti@gmail.com> | 2014-02-24 18:58:31 (GMT) |
commit | 6b532349d0464fa9151076d023cdea01031e6bae (patch) | |
tree | 1d82cd7884f28afa6d14d968033cf4b44047baa5 | |
parent | 94ee389308ec9e0e07b3f7a944d5179aba540c5e (diff) | |
download | cpython-6b532349d0464fa9151076d023cdea01031e6bae.zip cpython-6b532349d0464fa9151076d023cdea01031e6bae.tar.gz cpython-6b532349d0464fa9151076d023cdea01031e6bae.tar.bz2 |
#20740: desquarify 2.
-rw-r--r-- | Doc/tutorial/introduction.rst | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Doc/tutorial/introduction.rst b/Doc/tutorial/introduction.rst index 1225e20..9efd1ac 100644 --- a/Doc/tutorial/introduction.rst +++ b/Doc/tutorial/introduction.rst @@ -371,9 +371,9 @@ values. The most versatile is the *list*, which can be written as a list of comma-separated values (items) between square brackets. Lists might contain items of different types, but usually the items all have the same type. :: - >>> squares = [1, 2, 4, 9, 16, 25] + >>> squares = [1, 4, 9, 16, 25] >>> squares - [1, 2, 4, 9, 16, 25] + [1, 4, 9, 16, 25] Like strings (and all other built-in :term:`sequence` type), lists can be indexed and sliced:: @@ -389,12 +389,12 @@ All slice operations return a new list containing the requested elements. This means that the following slice returns a new (shallow) copy of the list:: >>> squares[:] - [1, 2, 4, 9, 16, 25] + [1, 4, 9, 16, 25] Lists also supports operations like concatenation:: >>> squares + [36, 49, 64, 81, 100] - [1, 2, 4, 9, 16, 25, 36, 49, 64, 81, 100] + [1, 4, 9, 16, 25, 36, 49, 64, 81, 100] Unlike strings, which are :term:`immutable`, lists are a :term:`mutable` type, i.e. it is possible to change their content:: |