用Matlab求[100,300]之间第五个能被21整除的整数。注:使用continue或break语句
n=100;
targetSeq = 5;
targetValue = 0;
NowSeq = 0;
while n<=300
if(mod(n,21)==0)
NowSeq = NowSeq+1;
if(NowSeq==targetSeq)
targetValue=n;
break;
else
n=n+1;
continue;
end
end
n=n+1;
end