Mercury 勉強メモ

関数論理型言語 Mercury を勉強するブログです.

2014-03-16から1日間の記事一覧

P-99: 1.28 Sorting a list of lists according to length of sublists

P-99: Ninety-Nine Prolog Problemsの問題にMercuryで解答していきます. a) [["o"], ["d", "e"], ["d", "e"], ["m", "n"], ["a", "b", "c"], ["f", "g", "h"], ["i", "j", "k", "l"]] b) [["i", "j", "k", "l"], ["o"], ["a", "b", "c"], ["f", "g", "h"], …

P-99: 1.27 Group the elements of a set into disjoint subsets

P-99: Ninety-Nine Prolog Problemsの問題にMercuryで解答していきます. a) ["aldo", "beat"]["carla", "david", "evil"]["flip", "gary", "hugo", "ida"] ["aldo", "beat"]["carla", "david", "flip"]["evil", "gary", "hugo", "ida"] ["aldo", "beat"]["c…