2024-03-25 16:05:20 +00:00
|
|
|
import java.lang.Boolean;
|
2024-03-26 09:54:32 +00:00
|
|
|
import java.lang.Integer;
|
2024-03-25 16:05:20 +00:00
|
|
|
|
|
|
|
public class Op1 {
|
2024-03-26 09:54:32 +00:00
|
|
|
public not() {
|
2024-03-25 16:05:20 +00:00
|
|
|
var b = false;
|
|
|
|
var c = !b;
|
|
|
|
return c;
|
2017-10-06 11:31:36 +00:00
|
|
|
}
|
2024-03-26 09:54:32 +00:00
|
|
|
|
|
|
|
public or() {
|
|
|
|
var a = 10;
|
|
|
|
var b = 20;
|
|
|
|
return a | b;
|
|
|
|
}
|
|
|
|
|
|
|
|
public and() {
|
|
|
|
var a = 10;
|
|
|
|
var b = 20;
|
|
|
|
return a & b;
|
|
|
|
}
|
|
|
|
|
|
|
|
public xor() {
|
|
|
|
var a = 10;
|
|
|
|
var b = 20;
|
|
|
|
return a ^ b;
|
|
|
|
}
|
2017-10-06 11:31:36 +00:00
|
|
|
}
|