package Mobile.OperatorsAndExpressions;
import java.util.Scanner;
public class RelationalOperators
{
public static void main(String args[])
{
Scanner sc=new Scanner(System.in);
int a,b;
System.out.println("Enter First Number");
a=sc.nextInt();
System.out.println("Enter Second Number");
b=sc.nextInt();
System.out.println("a---->"+a);
System.out.println("b---->"+b);
System.out.println("a>b---->"+(a>b));
System.out.println("a<b---->"+(a<b));
System.out.println("a>=b---->"+(a>=b));
System.out.println("a<=b---->"+(a<=b));
System.out.println("a==b---->"+(a==b));
System.out.println("a!=b---->"+(a!=b));
}
}
import java.util.Scanner;
public class RelationalOperators
{
public static void main(String args[])
{
Scanner sc=new Scanner(System.in);
int a,b;
System.out.println("Enter First Number");
a=sc.nextInt();
System.out.println("Enter Second Number");
b=sc.nextInt();
System.out.println("a---->"+a);
System.out.println("b---->"+b);
System.out.println("a>b---->"+(a>b));
System.out.println("a<b---->"+(a<b));
System.out.println("a>=b---->"+(a>=b));
System.out.println("a<=b---->"+(a<=b));
System.out.println("a==b---->"+(a==b));
System.out.println("a!=b---->"+(a!=b));
}
}
No comments:
Post a Comment
Note: only a member of this blog may post a comment.