min=40000
DO
INPUT a
IF a<>0 AND a MOD 7=0 AND a<min THEN min=a
LOOP UNTIL a=0
IF min<>40000 THEN PRINT min ELSE PRINT"takih chisel net"
min=40000
DO
INPUT a
IF a<>0 AND a MOD 7=0 AND a<min THEN min=a
LOOP UNTIL a=0
IF min<>40000 THEN PRINT min ELSE PRINT"takih chisel net"