0
Extracting Links From string
Hello I want to extract links from string ... I have created a code https://code.sololearn.com/cu9MsYUJS3qb/?ref=app But when I add links to it it gives me number of items.. Can you help me???
8 odpowiedzi
+ 2
Have you editted this code since your question? It's printing out a list for me, not the number in your list.
+ 1
But you're regex is giving the command otherwise. You're grouping, so it's giving you a list of all the groups. Have you done a lesson on Regex with Python?
+ 1
So I would recommend you take the Python course here on SL and then you'll learn once you get to the regex part of the course.
+ 1
I found this, maybe can help:
https://stackoverflow.com/questions/27745/getting-parts-of-a-url-regex
0
Justice No I mean, for a single link it give many outputs something like "https", "//" etc it should give us only one link
0
Justice for example I have give it user_input as Facebook link it should give output link only but it gives a list of many items like https // etc
0
Not yet I just copied this from google Justice
0
Justice thanks for your help I will look into it