Posts

Showing posts from June, 2019

# write a proagram area of circle

radius=float(input("Enter the radius= ")) area=3.14*radius*radius print("area of "+str(area)) output: Enter the radius= 6 area of 113.03999999999999

# Write a program to demonstrate relational operator

x= int(input("Enter the number of x:")) y=int(input("Enter the number of y:")) print(str(x)+"=="+str(y)+"="+str(x==y)) print(str(x)+"!="+str(y)+"="+str(x!=y)) print(str(x)+">"+str(y)+"="+str(x>y)) print(str(x)+"<"+str(y)+"="+str(x<y)) print(str(x)+">="+str(y)+"="+str(x>=y)) print(str(x)+"<="+str(y)+"="+str(x<=y)) output :     Enter the number of x:6 Enter the number of y:4 6==4=False 6!=4=True 6>4=True 6<4=False 6>=4=True 6<=4=False