DECLARE FUNCTION max2! (x AS SINGLE, y AS SINGLE)
CLS
INPUT "a="; a
INPUT "b="; b
INPUT "c="; c
INPUT "d="; d
x = max2(a, b)
y = max2(x, c)
z = max2(y, d)
PRINT "Max="; z
FUNCTION max2 (x AS SINGLE, y AS SINGLE)
IF x > y THEN max2 = x ELSE max2 = y
END FUNCTION
Тестирование выполнено в программе QB64 ( Скачать )