IDNLearn.com offers a seamless experience for finding and sharing knowledge. Our Q&A platform is designed to provide quick and accurate answers to any questions you may have.


Write a program in QBasic to enter two numbers and print the greater one.​


Sagot :

Answer:

REM

CLS

INPUT “ENTER ANY TWO NUMBERS”; A, B

IF A > B THEN

PRINT A; “IS GREATER”

ELSE

PRINT B; “IS GREATER”

END IF

END

class one

{

public static void main ( )

{

int a = 1,b = 2;

if ( a > b )

{

System.out.print (" greater number is " + a);

}

else if ( a < b )

{

System.out.print (" greater number is " + b);

}

}

}