def extractURL(s):
listURL = []
L = s.split()
for element in L:
if (element.startswith('https://') or element.startswith('http://')):
listURL.append(element)
return listURL
s = "como entrar site https://www.sapo.pt ou isto será um site https://www.jn.pt"
print(extractURL(s))