python infinity number code example
Example 1: infinity in python
# Defining a positive infinite integer
positive_infnity = float('inf')
print('Positive Infinity: ', positive_infnity)
# Defining a negative infinite integer
negative_infnity = float('-inf')
print('Negative Infinity: ', negative_infnity)
Example 2: python infinity
test = float("inf")