python if statement
usrinput = input(">> ")
if usrinput == "Hello":
print("Hi")
elif usrinput == "Bye":
print("Bye")
else:
print("Okay...?")
python if statement
usrinput = input(">> ")
if usrinput == "Hello":
print("Hi")
elif usrinput == "Bye":
print("Bye")
else:
print("Okay...?")
python conditionals
a == b (is equal)
a != b (is not equal)
a < b (a is less than b)
a > b (a is greater than b)
a <= b (a is less than or equal to b)
a >= b (a is greater than or equal to b)
conditional and in python
if 1 > 2 and 4 < 10:
print("condition not met")
if 4 < 10 or 1 < 2:
print("condition met")
condition ? expr If True : expr If False
condition ? expifTrue : expIfFalse;
conditional block python
a = 1
b = 2
if a < b:
print("a is less than b") #This will run since 1 is less than 2
elif a > b:
print("a is greater than b")
else:
print("a is equal to b")
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us