A famous syllogisme1 says:
All men are mortal.
Socrates is a man.
Therefore, Socrates is mortal.
The code block below assigns some sets to variables:
things
: a set
of all things (I know a few are missing, but for the sake of argument)
men
: a set
of all men (assuming that the first set indeed contains all things)
mortals
: a set of everything that is mortal (again, assuming…)
Using set
operators and methods, compose Boolean expressions (bool
) whose
results are assigned to the variables A
, B
, C
, D
and E
to show that
indeed
A
: all men are mortal
B
: Socrates is a man
C
: Socrates is mortal
D
: there are mortal things that are not men
E
: there are things that are not mortal