INPUT " vvedite kol-vo elementov ", n
DIM a(n)
RANDOMIZE TIMER
FOR i = 1 TO n
a(i) = INT(RND * 50)
NEXT
PRINT "massiv"
FOR i = 1 TO n
PRINT a(i);
NEXT
PRINT
m = 1
FOR i = 1 TO n
IF a(i) > a(m) THEN m = i
NEXT
t = a(m)
PRINT "naibolshiy element="; t
FOR i = m TO 2 STEP -1
a(i) = a(i - 1)
NEXT
a(1) = t
PRINT "novyj massiv"
FOR i = 1 TO n
PRINT a(i);
NEXT