def main():
	website = input("Input website(cnn, nytimes, bbc, nzherald): ") 
	url = input("Input url: ")
	scraper(website, url)
def scraper(website, url):
	print("%s, %s" % (website, url))
if __name__ == '__main__':   
     main()
def main():
	website = input("Input website(cnn, nytimes, bbc, nzherald): ") 
	url = input("Input url: ")
	scraper(website, url)
def scraper(website, url):
	if ".com" not in url:
		print("Invalid url")
		exit()
	print("%s, %s" % (website, url))
if __name__ == '__main__':   
     main()
Check for .com in url
Check for .com in url

  def main():
  	website = input("Input website(cnn, nytimes, bbc, nzherald): ") 
  	url = input("Input url: ")
  	scraper(website, url)
  def scraper(website, url):
+ 	if ".com" not in url:
+ 		print("Invalid url")
+ 		exit()
  	print("%s, %s" % (website, url))
  if __name__ == '__main__':   
       main()
Check for .com in url
## Code Before:
def main():
	website = input("Input website(cnn, nytimes, bbc, nzherald): ") 
	url = input("Input url: ")
	scraper(website, url)
def scraper(website, url):
	print("%s, %s" % (website, url))
if __name__ == '__main__':   
     main()
## Instruction:
Check for .com in url
## Code After:
def main():
	website = input("Input website(cnn, nytimes, bbc, nzherald): ") 
	url = input("Input url: ")
	scraper(website, url)
def scraper(website, url):
	if ".com" not in url:
		print("Invalid url")
		exit()
	print("%s, %s" % (website, url))
if __name__ == '__main__':   
     main()