CLS
TYPE rabotnik
fam AS STRING * 20
pol AS STRING * 2
vozr AS INTEGER
adr AS STRING * 40
otd AS STRING * 20
END TYPE
n = 10
DIM a(n) AS rabotnik
FOR i = 1 TO n
PRINT "Vvedite dannie rabotnika #"; i
INPUT "Familiya"; a(i).fam
INPUT "pol (m,zh)"; a(i).pol
INPUT "vozrast"; a(i).vozr
INPUT "adres"; a(i).adr
INPUT "otdel"; a(i).otd
CLS
NEXT
PRINT "Familiya";
LOCATE , 20
PRINT "pol";
LOCATE , 25
PRINT "vozrast";
LOCATE , 37
PRINT "adres";
LOCATE , 60
PRINT "otdel"
PRINT
FOR i = 1 TO n
PRINT a(i).fam;: LOCATE , 20:
PRINT a(i).pol;: LOCATE , 25
PRINT a(i).vozr;: LOCATE , 34
PRINT a(i).adr;: LOCATE , 60
PRINT a(i).otd
NEXT
PRINT: PRINT
PRINT "Rabotniki ne starshe 45 let"
FOR i = 1 TO n
IF a(i).vozr <= 45 THEN PRINT a(i).fam
NEXT
DIM p AS STRING * 20
PRINT
INPUT "Vvedite nazvanie otdela"; p
k = 0
FOR i = 1 TO n
IF p$ = a(i).otd THEN k = k + 1
NEXT
PRINT "Kolvo rabotnikov otdela "; p; "="; k
Тестирование выполнено в программе QB64 ( Скачать )