xref: /openbsd/regress/usr.bin/bc/t15.in (revision 7b36286a)
1if (1 && 2) "ok1"
2if (0 && 2) "nok2" else "ok2"
3if (3 && 0) "nok3" else "ok3"
4if (0 && 0) "nok4" else "ok4"
5if (0 && 0 && 0) "nok5" else "ok5"
6if (0 && 1 && 0) "nok6" else "ok6"
7if (1 && 1 && 1) "ok7" else "nok7"
8print "\n"
9define f() {
10	"f"
11}
12define g() {
13	"g"
14	return 1
15}
16if (f() && g()) {
17	"nok8"
18} else "ok8"
19if (!f() && g()) {
20	"ok9"
21} else "nok9"
22print "\n"
23if (1 < 2 && 3 < 4) "ok10" else "nok10"
24print "\n"
25