for ((i=1; i<=100; i–))
do
let j=i-1
starttime=$(date -d “20201201 07:30:00 KaTeX parse error: Expected 'EOF', got '#' at position 33: …%M%S") #̲指定时间增加1天 …(date -d “20201201 07:30:00 $i day” +”%Y%m%d%H%M%S")
echo $starttime
echo $endtime
done
以上代码能实现日期循环,