aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools/lua/scrape.lua
blob: 1d9cda91fe5954800442d301e148c9302d091357 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
canvas = {}
total = 0
function accumulate(verb)
  total = total + 1
  n = canvas[verb] or 0
  n = n + 1
  canvas[verb] = n
end
function summarize()
  io.write('total='..total..' ')
  for k, v in next, canvas do
    io.write(k..'='..v..' ')
  end
end