more if examples
This commit is contained in:
parent
0b8a159a9b
commit
faabeabea5
11
elif-2.py
Normal file
11
elif-2.py
Normal file
|
@ -0,0 +1,11 @@
|
|||
a = int(input('Bir sayı giriniz:'))
|
||||
if a == 1:
|
||||
print('Bir')
|
||||
elif a == 2:
|
||||
print('İki')
|
||||
elif a == 3:
|
||||
print('Üç')
|
||||
elif a == 4:
|
||||
print('Dört')
|
||||
else:
|
||||
print('Diğer')
|
16
true-false-else-if.py
Normal file
16
true-false-else-if.py
Normal file
|
@ -0,0 +1,16 @@
|
|||
a = int(input("Bir değer giriniz:"))
|
||||
if a:
|
||||
print('Doğru')
|
||||
else:
|
||||
print('Yanlış')
|
||||
b = []
|
||||
if b:
|
||||
print('Doğru')
|
||||
else:
|
||||
print('Yanlış')
|
||||
|
||||
s = input('Bir yazı giriniz:')
|
||||
if s:
|
||||
print('Doğru')
|
||||
else:
|
||||
print('Yanlış')
|
Loading…
Reference in New Issue
Block a user