Making Spam message Detector using if else condition
# Program to detect spam msg
text = input("Enter the message\n")
if("make money online" in text):
spam = True
elif(" subscribe this" in text):
spam = True
elif("click this" in text):
spam = True
elif("buy now" in text):
spam = True
elif("offer closes soon" in text):
spam = True
elif("be a crorepati" in text):
spam = True
else:
spam = False
if(spam):
print("Be careful...! This is a spam message ")
else:
print("Don't worry...! This is not a spam ")
Comments
Post a Comment