Random numbers, if, else if
<p>Im writing JavaScript code like this:</p>

<pre><code>function rollTrigger() {
var roll = Math.round(Math.random()*999999999+1);
var result = document.getElementById("result");

if (roll &lt;= 50900000) {
    result.innerHTML = "Category 0";
    BoLPamount += 1;
    document.getElementById("boxlesserprizes").innerHTML = "Box of Lesser Prizes " + BoLPamount; 
    log.innerHTML += "&lt;br /&gt;Trigger - win = true; Category 0"; //LOG        
} else if (roll &lt;= 900000) {
    result.innerHTML = "Category A";
    log.innerHTML += "&lt;br /&gt;Trigger - win = true; Category A"; //LOG
} else if (roll &lt;= 360000) {
    result.innerHTML = "Category B";
    log.innerHTML += "&lt;br /&gt;Trigger - win = true; Category B"; //LOG
} else if (roll &lt;= 211890) {
    result.innerHTML = "Category C";
    log.innerHTML += "&lt;br /&gt;Trigger - win = true; Category C"; //LOG
} else if (roll &lt;= 109020) {
    result.innerHTML = "Category D";
    log.innerHTML += "&lt;br /&gt;Trigger - win = true; Category D"; //LOG
} else if (roll &lt;= 56505) {
    result.innerHTML = "Category E";
    log.innerHTML += "&lt;br /&gt;Trigger - win = true; Category E"; //LOG
} else if (roll &lt;= 34888) {
    result.innerHTML = "Category F";
    log.innerHTML += "&lt;br /&gt;Trigger - win = true; Category F"; //LOG
} else if (roll &lt;= 15574) {
    result.innerHTML = "Category G";
    log.innerHTML += "&lt;br /&gt;Trigger - win = true; Category G"; //LOG
} else {
    result.innerHTML = "MEH";
    log.innerHTML += "&lt;br /&gt;Trigger - win = false"; //LOG
};
document.getElementById("roll").innerHTML = roll;
</code></pre>

<p>};</p>

<p>But it's not working properly... For example if the random number is 40200000 then it shows the "Category 0" as supposed to, however even if the random number is 10 it still shows "Category 0" instead of "Category G". Any idea whats wrong?</p>
