scala算法练习--数组旋转
scala算法练习–数组旋转Odef rotate(nums: Array[Int], k: Int): Unit = { val len=nums.length if(len==1 || k==0 || len==k) return var i=0 var j=0 var index=j var temp =nums(index) do { val next=nums((inde