62 Program to demonstrate Boolean function in Python

Program:

#Boolean function:function which returns either True/false

x=20

y=10



def f1():

    if(x>y):

        return True

    else:

        return False

p=f1()

print(p)


Output:
     
Program to demonstrate Boolean function in Python

Previous
Next Post »