22 lines
581 B
Text
22 lines
581 B
Text
module test {
|
|
@Inject Console console;
|
|
|
|
static Boolean show(String name, Boolean value) {
|
|
console.print($"{name}()={value}");
|
|
return value;
|
|
}
|
|
|
|
void run() {
|
|
val a = show("a", _);
|
|
val b = show("b", _);
|
|
|
|
for (Boolean v1 : False..True) {
|
|
for (Boolean v2 : False..True) {
|
|
console.print($"a({v1}) && b({v2}) == {a(v1) && b(v2)}");
|
|
console.print();
|
|
console.print($"a({v1}) || b({v2}) == {a(v1) || b(v2)}");
|
|
console.print();
|
|
}
|
|
}
|
|
}
|
|
}
|