I've seen other questions which will parse either all plain links, or all anchor tags from a string, but nothing that does both.

Ideally, the regular expression will be able to parse a string like this (I'm using Python):

```
>>> import re
>>> content = '
    <a href="http://www.google.com">http://www.google.com</a> Some other text.
    And even more text! http://stackoverflow.com
    '
>>> links = re.findall('some-regular-expression', content)
>>> print links
[u'http://www.google.com', u'http://stackoverflow.com']

```

Is it possible to produce a regular expression which would not result in duplicate links being returned? Is there a better way to do this?