I am in the process of adding a deduplication builtin to my Jacinda language. It's something I've wanted often enough and evidently part of the reason people use awk (it is the way to deduplicate on the command line without changing order).
Consider this awk script from glibc:
NF == 1 && $1 != "}" {
haveversion[$1] = 1
}
END {
for (i in haveversion)
printf "have-%s = yes\n", i
}
The equivalent in Jacinda would be:
(sprintf 'have-%s = yes')ยจ ~.{nf=1 & `1 != '}'}{`1}
where ~.
is the unary prefix deduplication operator.
Certainly a more functional style. When Jacinda is enough to replace awk, I think it is an elegant choice.