Table of Contents
Overview
Below is the program to find the greater number among any two user-entered numbers.
REM Program to find the greater number among two numbers CLS INPUT "Enter the first number: "; a INPUT "Enter the second number: "; b IF a > b THEN PRINT a; " is greater than ";b ELSE PRINT b; " is greater than ";a END IF END
Output
Explanation
To find the greater number among two numbers, ask two numbers from the user and check if the first number is greater than the other using the greater than (>) comparison operator.
More Programs
https://thinkshare.one/learn/programming/qbasic/