Module:ListCount

local p = {}

function p.main(frame) local list = frame.args.list local bullet = string.format('%%%s+', frame.args[1]) _, count = list:gsub(bullet, '') return string.format(       'There are %d %s in this list.\n%s',        mw.getContentLanguage:formatNum(count),        count == 1 and 'item' or 'items',        list    ) end

return p