CLS
INPUT "Vvedite slovo"; a$
n = LEN(a$)
DIM b$(n)
FOR i = 1 TO n
b$(i) = MID$(a$, i, 1)
NEXT i
s = 0
FOR i = 1 TO n
k = 0
FOR j = i + 1 TO n
IF b$(j) = b$(i) THEN k = k + 1
NEXT j
IF k > s THEN s = k: bukv$ = b$(i)
NEXT i
IF s > 0 THEN
PRINT "bukva "; bukv$; " v slove "; a$; " vstrechaetsya chashe"
ELSE
PRINT "kazhdaya bukva v slove "; a$; " vstrechaetsya odin raz"
END IF
END
Тестирование выполнено в программе QB64 ( Скачать )