How to get an integer value from string(may be url) in python
===

Suppose i had a url as below

    url = 'https://www.advertise-example.com/ads/2022/presents'

Now i am trying to get the integer value `2022` out from the above url.we can use list slicing here, but the integer value can be increased, so i used regular expressions but couldn't get the exact result, can anyone tell me how to do this


Thanks in advance........