odd and even

This commit is contained in:
Mert Gör 🇹🇷 2023-05-20 15:39:13 +03:00
parent 135cf9ae63
commit a98f3b67b4
No known key found for this signature in database
GPG key ID: 2100A876D55B39B9

11
odd.even.py Normal file
View file

@ -0,0 +1,11 @@
a = [23, 56, 44, 12, 13, 97, 45, 39, 80, 54]
odd = []
even = []
for i in a:
if i % 2 == 0:
even.append(i)
else:
odd.append(i)
print(odd)
print(even)