Dim Arr(1 To N) As Double
'Ищем первый максимальный элемент
Dim i1stMax As Long
Dim d1stMax As Double
Dim i As Long
i1stMax = 1
d1stMax = Arr(1)
For i = 2 To N
If Arr(i) > d1stMax Then
i1stMax = i
d1stMax = Arr(1)
End If
Next i
Dim iShift As Long 'Фактор сдвига
iShift = N - i1stMax
While iShift > 0
' Сдвигаем циклически на 1 вправо
Dim dN As Double
dN = Arr(N)
For i = N To 2 Step -1
Arr(i) = Arr(i - 1)
Next i
Arr(1) = dN
iShift = iShift - 1
Wend