I'm new to coding and this is my first question here! I'm trying to do some automation tools and in my first step i want to get data from the user and validate it.
I'm trying to get domain name from user and check the TLD if its '.co.il' keep to other task if not print a msg.
I read and try few things but nothing work for me.
This is my last try code:
domainBuy = input('Please Enter Domain Name: ')
def domaincheck(domainBuy):
if '.co.il' in domainBuy:
print('DOMAIN GOOD!')
else:
print('bad')
I will appreciate any tips! Thanks!