Home »
Python
Python False Keyword
By IncludeHelp Last updated : December 07, 2024
Description and Usage
The False is a keyword (case-sensitive) in python, it is a Boolean value (a value of class type bool). False is the result of a comparison operation.
Syntax
Syntax of False keyword:
False
Sample Input/Output
Input:
x = False
# print
print(x)
Output:
False
Example 1
Assign False to a variable, print the value and print type of False.
# python program to demonstrate example of
# False keyword
# assigning False to a variable
x = False
# printing the value
print("x: ", x)
# printing type of False
print("Type of False:", type(False))
Output
x: False
Type of False: <class 'bool'>
Example 2
Printing the result of some of the comparison operations.
# python program to demonstrate example of
# False keyword
# assigning False to a variable
x = False
# printing the value
print("x: ", x)
# printing type of False
print("Type of False:", type(False))
Output
False
False
False
False