RosettaCodeData/Task/Ternary-logic/Tcl/ternary-logic-2.tcl
Ingy döt Net 68f8f3e56b all tasks
2013-04-11 01:07:29 -07:00

10 lines
278 B
Tcl

namespace import ternary::*
puts "x /\\ y == x \\/ y"
puts " x | y || result"
puts "-------+-------++--------"
foreach x {true maybe false} {
foreach y {true maybe false} {
set z [equiv [and $x $y] [or $x $y]]
puts [format " %-5s | %-5s || %-5s" $x $y $z]
}
}