Calculating number of seats in parliament using d’Hondt’s method

Wikipedia contains an article on d’Hondt’s method for calculating the number of seats given the number of votes for each party. I wrote a short Perl program for its calculation including the case when d’Hondt’s method by its design leads to drawing the lots. Its input contains a list of party names and its corresponding votes. The number of seats is given as parameter -s. This implementation of d’Hondt uses integer division and rounds the division to the lower integer (floor).

Continue reading

Statistics of this Blog: 2.600 Views, 78 Countries, 20 Comments

In two previous posts

  1. My Blog Statistics by Country and
  2. Statistics of this Blog: 1.000 Views, 60 Countries, 10 Likes

I showed the statistics of this blog in September and October last year. The last few weeks I was quite heavily loaded with work, so I couldn’t announce that I broke the 2.000 views barrier. Here are the numbers.

Continue reading