GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — JavaTutorial-2/src/4_RelationalOperator.java at master · dynamo07/JavaTutorial-2

Expand file tree

/

4_RelationalOperator.java

Copy path
More file actions
More file actions

Latest commit

 

History

History
History
32 lines (26 loc) · 644 Bytes
/

4_RelationalOperator.java

Copy path

File metadata and controls

32 lines (26 loc) · 644 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
/**
*
* Relational Operator
* */
public class Main {
public static void main(String[] args) {
int x = 2;
int y = 3;
int z = 3;
// Greater than and Greater than equal to
boolean r1 = x > y; // r1 = false
boolean r2 = y >= z; // r2 = true
// Less than or less than equal to
boolean r3 = y < x; // r3 = false
boolean r4 = x <= y; // r4 = true
// Is equal to and Is not equal to
boolean r5 = x == y; // r5 = false
boolean r6 = (x != y); // r6 = true
System.out.println(r1);
System.out.println(r2);
System.out.println(r3);
System.out.println(r4);
System.out.println(r5);
System.out.println(r6);
}
}
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.