-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAssignmentTest.java
More file actions
29 lines (23 loc) · 551 Bytes
/
AssignmentTest.java
File metadata and controls
29 lines (23 loc) · 551 Bytes
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
package dt;
public class AssignmentTest {
public static void main(String[] args) {
int x = 10;
if (x > 0 && x == 10) {
System.out.println("x is greate then 0: X= " + x);
}
if (x > 0 || x == 50) {
System.out.println("x is greate then 0");
}
int y = 50;
y = y + 10; // 60
System.out.println(y);
y += 10; // 70
System.out.println(y);
AssignmentTest obj = new AssignmentTest();
obj.show();
}
public void show() {
double sin30 = Math.sin(Math.PI / 6);
System.out.println(sin30);
}
}