DEFINT A-Z
CLS
DIM A(27), B(27), C(27)
RANDOMIZE TIMER
FOR i = 0 TO 27
A(i) = RND * 51
B(i) = RND * 51
C(i) = RND * 51
PRINT A(i);
NEXT: ?
FOR i = 0 TO 27
PRINT B(i);
NEXT: ?
FOR i = 0 TO 27
PRINT C(i);
NEXT: ?
' Считаем
FOR i = 0 TO 27
S1 = S1 + A(i)
S2 = S2 + B(i)
S3 = S3 + C(i)
NEXT
S1 = S1 / 28
S2 = S2 / 28
S3 = S3 / 28
PRINT "Srednie arifm massivov : "; S1; S2; S3
IF S1 > S2 THEN SWAP S1, S2
IF S2 > S3 THEN SWAP S2, S3
IF S1 > S2 THEN SWAP S1, S2
PRINT "Minimalnoe sr. arifmetich : "; S1
Тестирование выполнено в программе QB64 ( Скачать )