大神好,我在python中,想在
http://paper.people.com.cn/rm...
后面加上一年的年月日,
就是变成:
http://paper.people.com.cn/rm...
http://paper.people.com.cn/rm...
http://paper.people.com.cn/rm...
http://paper.people.com.cn/rm...
....
http://paper.people.com.cn/rm...
http://paper.people.com.cn/rm...
该用什么办法呢?
刚看了自己的提问,没显示全,补充上图片,谢谢。
The datetime module can generate time series and then concatenate strings.
If it is a crawler, the parameters in requests.get() in the Requests module can also be spliced.
Uh-huh. . . Allow me to tell you a dumber way.
I mainly do data analysis and visualization, and I am not a computer person. When I encounter problems, I first look for ready-made functions.
Python method to get specific time in the past:
Python method to get specific time in the future:
For details, you can check out this Python time operation example and summary of time formatting parameters http://www.php.cn/python-tuto...