大久保弘崇
Errata-1
最終更新:
hirotakaohkubo
-
view
Chapter 1
p.3 l.8
Wrong:
Correct:
p.4 typo
Wrong:
Correct:
Chapter 2
p.8 l.-3, l.-6 typo
Wrong:
Correct:
p.10 l.5-7
Discussion here is corrupted by new sorted definitions and old unsorted one.
Especially,
Especially,
Counterexample :
let
let
ys = "bab"
so
tys = table ys = [('a',1),('b',0),('b',0)], x = y = 'a', d = 1, tys' = [('b',0),('b',0)]
Now
tcount x tys' = 2 /= d
Here is my proposal:
(p.9, below (2.1))
(p.9, below (2.1))
table xs = sortBy (\a b-> compare (fst a) (fst b)) xs
(p.10 l.5-7)
When x > y, (2.3) reduces to (y,d):join txs tys' .
When x = y, You have 2 choices.
If you choose the txs side, discussion above cannot apply, so (2.3) reduces to (x, c + length (dropWhile ((x >=) . fst) tys)) : join n txs' tys .
If you choose the tys side, (2.3) reduces to (y,d):join txs tys' .
It is clear we should choose the latter.
When x > y, (2.3) reduces to (y,d):join txs tys' .
When x = y, You have 2 choices.
If you choose the txs side, discussion above cannot apply, so (2.3) reduces to (x, c + length (dropWhile ((x >=) . fst) tys)) : join n txs' tys .
If you choose the tys side, (2.3) reduces to (y,d):join txs tys' .
It is clear we should choose the latter.
p.11
Wrong:
Rem, M. (1998b). Small programming exercises 21. Science of Computer Programming 10 (3), 319–25.
Correct:
Rem, M. (1988b). Small programming exercises 21. Science of Computer Programming 10 (3), 319–325.
Page number is his style?
Rem, M. (1998b). Small programming exercises 21. Science of Computer Programming 10 (3), 319–25.
Correct:
Rem, M. (1988b). Small programming exercises 21. Science of Computer Programming 10 (3), 319–325.
Page number is his style?