removed useless file
[qmc.git] / flat.lua
blobae0bf471fe1d159e5898daf47a39479d820b9b31
1 #!/usr/bin/lua
3 -- checks the distribution of numbers in a data file
5 local f = io.open(... or 'test')
7 local t = {}
8 local l = f:read()
9 while l do
10 t[tonumber(l)] = (t[tonumber(l)] or 0) + 1
11 l = f:read()
12 end
14 f:close()
16 for i, n in ipairs(t) do
17 print(i, n)
18 end