fix. add missing guard function.

This commit is contained in:
Kei Hibino 2016-09-17 15:59:42 +09:00
parent 9db197e7d8
commit f09375d95b
2 changed files with 122 additions and 105 deletions

File diff suppressed because one or more lines are too long

View File

@ -16,7 +16,7 @@ $$\{ (x, y) | x \in X, y \in Y, \pi_1(x) = \pi_2(y) \}$$
[ (x, y) | x <- xs, y <- ys, fst x == snd y ]
-- List Monad
do { x <- xs; y <- ys; fst x == snd y; return (x, y) }
do { x <- xs; y <- ys; guard (fst x == snd y); return (x, y) }
~~~~~