|
74.
|
|
|
An integer is a number without a decimal point. ``3`` and ``42`` are integers.
|
|
|
|
(no translation yet)
|
|
|
|
Located in
../../source/language_basics.rst:278
|
|
75.
|
|
|
:dfn:`Float`
|
|
|
|
(no translation yet)
|
|
|
|
Located in
../../source/language_basics.rst:283
|
|
76.
|
|
|
A float (short for floating-point number) is a number with a decimal point. ``.5``, ``7.``, and ``9.0`` are all floats.
|
|
|
|
(no translation yet)
|
|
|
|
Located in
../../source/language_basics.rst:282
|
|
77.
|
|
|
Python strings begin with " or ', and end with the same character. \\ is used to escape the end character, and to introduce special characters like newlines (\\n). Unlike Ren'Py strings, python strings can't span lines.
|
|
|
|
(no translation yet)
|
|
|
|
Located in
../../source/language_basics.rst:286
|
|
78.
|
|
|
:dfn:`True, False, None`
|
|
|
|
(no translation yet)
|
|
|
|
Located in
../../source/language_basics.rst:294
|
|
79.
|
|
|
There are three special values. ``True`` is a true value, ``False`` is a false value. ``None`` represents the absence of a value. For example,
|
|
|
|
(no translation yet)
|
|
|
|
Located in
../../source/language_basics.rst:292
|
|
80.
|
|
|
:dfn:`Tuple`
|
|
|
|
(no translation yet)
|
|
|
|
Located in
../../source/language_basics.rst:310
|
|
81.
|
|
|
Tuples are used to represent containers where the number of items is important. For example, one might use a 2-tuple (also called a pair) to represent width and height, or a 4-tuple (x, y, width, height) to represent a rectangle.
|
|
|
|
(no translation yet)
|
|
|
|
Located in
../../source/language_basics.rst:297
|
|
82.
|
|
|
Tuples begin with a left-parenthesis ``(``, consist of zero or more comma-separated python expressions, and end with a right-parenthesis ``)``. As a special case, the one-item tuple must have a parenthesis following the item. For example::
|
|
|
|
(no translation yet)
|
|
|
|
Located in
../../source/language_basics.rst:302
|
|
83.
|
|
|
:dfn:`List`
|
|
|
|
(no translation yet)
|
|
|
|
Located in
../../source/language_basics.rst:320
|