I need to find all website addresses in the input text and print all addresses in the order they appear in the text, each on a new line. "https: //" "http: //" "www."
I used split in the string, but I can't return that start with this 'www'. Can someone explain to me how can I solve this?
Sample Input 1:
WWW.GOOGLE.COM uses 100-percent renewable energy sources and www.ecosia.com plants a tree for every 45 searches!
Sample Output 1:
WWW.GOOGLE.COM
text = input()
text = text.lower()
words = text.split(" ")
for word in words: