Write a program in qbasic to display whether the given number is even or odd using SUB procedure
Answers
Answered by
0
Answer:
CLS
INPUT A
IF A MOD 2 =0 THEN
PRINT "EVEN";
ELSE
PRINT "ODD";
END IF
END
SUB......END SUB
DECLARE SUB EOO(A)
INPUT A
CALL EOO(A)
END
SUB EOO(A)
IF A MOD A = 0 THEN
PRINT "EVEN"
ELSE
PRINT "ODD"
END IF
END SUB
FUNCTION....END FUNCTION
Similar questions
India Languages,
4 months ago
Physics,
4 months ago
Geography,
4 months ago
Math,
8 months ago
Biology,
1 year ago