python-beginner - 4 - if else



If 
if 3>2:
    print('Hi')# Hi


if True:
    print('Hi') # Hi

isLoggedin = True
if isLoggedin:
    print('Hi') # Hi

Else
if 3>2:
    print('Hi')# Hi
else:
    print('something went wrong')

Elif
x = int(input('x: '))
y = int(input('y: '))

if x >2 y:
    print('x y den buyuk')
elif x == y:
    print('x yye esittir')
else:
    print('y x den buyuk')



Comments

Popular posts from this blog

python - pro - 20 - SQLite

python - pro - 21 - NoSQL

python-beginner - 1 - strings splits