評分:0, 年:0, 月:0, 週:0, 日:0, [+1 / -1] 最後更新:2017-09-08 08:52:49
http://rem.komica2.net/00/pixmicat.php?res=9811416
//------
[aa]
function rotationLeft(SourceArray,LeftMove){
var aryInt = SourceArray;
var intLength = aryInt.length;
var intMaxPoint = intLength - 1;
var intMove = LeftMove % intLength;
var intFirstChangePoint = 0;
//--------
var intIndex = 0;
//--
var intChangeTo = (intIndex+intMove);
do{
if(intFirstChangePoint == intIndex){
intFirstChangePoint = (intIndex+intMove);
}
Change(aryInt,intIndex,(intIndex+intMove));
intChangeTo++;
intIndex++;
}
while(intChangeTo < intLength);
//--
var intPointFixFisrt = intIndex;
var intPoint = 0+intFirstChangePoint;
do{
if(intPointFixFisrt == intIndex){
intPointFixFisrt = intPoint;
}
Change(aryInt,intIndex,intPoint);
if(intPoint == intMaxPoint){
intPoint = intPointFixFisrt;
}
else{
intPoint++;
}
intIndex++
}while(intIndex < intMaxPoint);
}
[/aa]