val ll = [[1,2], nil, [3], [4,5,6]]; fun eqLists(nil) = true | eqLists(nil::YS) = eqLists(YS) | eqLists((x::xs)::(y::ys)) = (x = hd(y)) andalso eqLists(xs::ys);