I don't want to be dismissive but I think TeX is more complex and uses non trivial algorithms. So it's like comparing an apple to an orange.
I don't want to be dismissive but I think TeX is more complex and uses non trivial algorithms. So it's like comparing an apple to an orange.
If you're going to compare qmail to something else though I think it should be compared to sendmail (or postfix for that matter), not to TeX.
Personally I think djb is a great coder, but there are quite a few of those around.
Programming is not a single-valued enterprise anyway, so best is a very hard to measure quantity, as good as meaningless. But I know 'bad' when I see it :)
From a systems programming perspective, qmail is not only nontrivial, but actually groundbreaking. His allocator design, the way he architected his libc replacement, the extent to which he takes advantage of bare-metal Unix programming (look at his queue notification mechanism), it's all really cool stuff.
But there's a big difference between theoretical CS and systems programming, and the parent commenter is right to point out that TeX is more complicated from a CS perspective than qmail is.