代码随想录算法训练营第二天 | 数组part02:209.长度最小的子数组 ,59.螺旋矩阵II ,区间和,开发商购买土地
209.长度最小的子数组classSolution{public:intminSubArrayLen(inttarget,vector&nums){intslow=0,fast=0,size=nums.size();intsum=0;queueqe;intres=INT_MAX;while(fast=target){if(res>qe.size()){res=qe.size();}sum-=qe.