You are a Winner!

I would like to say thank you to everyone who participated in my little giveaway. This little piece of javascript has chosen the lucky pilot, who will have a brand new Talos battlecruiser:

document.write(1+Math.floor(Math.random()*10));

As many of you know, Math.random() returns a pseudorandom number between 0 and 1. Ten people commented under the post, so we need a range from 1 to 10. We have to multiply the output by 10 and add one, so the output range starts with 1. The last step is to truncate the fraction part. We can do it with the Math.floor() function.

The winning number is 8.

The eighth person to comment (not the 8th comment! one of the participants has commented twice) was…

Rathann

Congratulations! I have contracted your ship to you in the game.