- Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathEx6Math.java
More file actions
Latest commit
17 lines (14 loc) · 552 Bytes
/
Copy pathEx6Math.java
File metadata and controls
17 lines (14 loc) · 552 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
packageJavaEntry;
publicclassEx6Math {
publicstaticvoidmain(String[] arg){
bytex = 10;
bytey = 5;
intMaxValue = Math.max(x, y);
intMinValue = Math.min(x, y);
intRandomValue = (int) (Math.random() * 11);
intPositiveValue = Math.abs(-79);
System.out.println("Max value is: " + MaxValue + " and Min value is: " + MinValue);
System.out.println("Make this positive: " + PositiveValue);
System.out.println("Random value between two 1 to 10: " + RandomValue);
}
}