Base constant False True None notimplemented ellipsis __debug__ site module added constants quitcodenone exitcodenone Copyright license Credits
Basic Constants
There are only a few constants in the built-in domain name: False
[Boolean type] [1] The negative value assigned to the False keyword is illegal and can cause syntaxerror. true¶
The truth value of a Boolean type, which is illegal to assign to the True keyword, and can cause syntaxerror. None
[Nonetype] [2] A private value of type, none is frequently used to represent a missing value, that is, when the default parameter is not passed to the function. assigning to the None keyword is illegal and can cause syntaxerror. notimplemented
A special value returned by a binary-specific method (for example, eq(), Lt(), add(), rsub(), and so on) to represent an operation that is not achievable with other classes; for the same purpose, It may also be returned through an in-place (in-place) binary special method. Its truth is true (WTF).
Note: When notimplemented is returned, the interpreter will then attempt a reflection operation on another type, or some other fallback (dependent operator).
See for details [Implementing arithmetic operations][3] ellipsis
Most of this special value is used to combine slice syntax that is extended for user-defined container data types. __debug__
This constant is true if Python is not started with AN-O option. Also the Assert statement.
If Python does not start with the-o option, the constant is true, see the [assert][4] statement for details.
Note: The names of None, False, True, and __debug__ cannot be reassigned (assigning values, even property names, will throw SyntaxError), so they can be considered "true" constants. Add constant for site module
[Site] [5] Modules (modules that can be imported automatically at startup, unless given the-S command-line option) can add several constants to the built-in namespaces, which are useful for interactive parsing of shells, but should not be used in programs. quit (code=none) exit (Code=none)
When printing an object, print information such as use Quit () or ctrl-d to exit, and when the object is invoked, the systemexit is raised with the specified exit code. Copyright License credits
When you print the object, print the information as "Type license () to" license text, and when you call the object, display the corresponding text in the page style (one page at a time).