Moerderhoschi – User talk
Jump to navigation
Jump to search
Killzone Kid (talk | contribs) (→round: new section) |
Lou Montana (talk | contribs) m (Text replacement - "Killzone Kid" to "Killzone_Kid") |
||
(4 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
== round == | == round == | ||
<dl class="command_description"> | <dl class="command_description"> | ||
<dt></dt> | |||
<dd class="notedate">Posted on August 28, 2015 - 13:59 (UTC)</dd> | <dd class="notedate">Posted on August 28, 2015 - 13:59 (UTC)</dd> | ||
<dt class="note">[[User:Moerderhoschi|Moerderhoschi]]</dt> | <dt class="note">[[User:Moerderhoschi|Moerderhoschi]]</dt> | ||
<dd class="note"> | <dd class="note"> | ||
please note when using the round command that the first and the last digit of the range occur only the half of the time then the other digits. Tested with | please note when using the round command that the first and the last digit of the range occur only the half of the time then the other digits. Tested with Arma 2 v1.62 | ||
<br>This is a normal behaviour because of the roundrange for the digit. | <br>This is a normal behaviour because of the roundrange for the digit. | ||
<br> 0 -> 0.00 - 0.49 -> roundrange is ~0.5 | <br> 0 -> 0.00 - 0.49 -> roundrange is ~0.5 | ||
Line 14: | Line 14: | ||
<br> 3 -> 2.50 - 3.49 -> roundrange is ~1 | <br> 3 -> 2.50 - 3.49 -> roundrange is ~1 | ||
<br> 4 -> 3.50 - 4.00 -> roundrange is ~0.5 | <br> 4 -> 3.50 - 4.00 -> roundrange is ~0.5 | ||
<code>countArray = [0,0,0,0,0]; | <code style="display: block">countArray = [0,0,0,0,0]; | ||
for "_i" from 1 to 10000 do { | for "_i" from 1 to 10000 do { | ||
number = (round random 4); | number = (round random 4); | ||
Line 24: | Line 24: | ||
</dd> | </dd> | ||
</dl> | </dl> | ||
I deleted your note. What you observed is [[random]] command distribution and not [[round]] doings. [[User: | I deleted your note. What you observed is [[random]] command distribution and not [[round]] doings. [[User:Killzone_Kid|Killzone_Kid]] ([[User talk:Killzone_Kid|talk]]) 16:20, 28 August 2015 (CEST) |
Latest revision as of 13:48, 12 March 2024
round
- Posted on August 28, 2015 - 13:59 (UTC)
- Moerderhoschi
-
please note when using the round command that the first and the last digit of the range occur only the half of the time then the other digits. Tested with Arma 2 v1.62
This is a normal behaviour because of the roundrange for the digit.
0 -> 0.00 - 0.49 -> roundrange is ~0.5
1 -> 0.50 - 1.49 -> roundrange is ~1
2 -> 1.50 - 2.49 -> roundrange is ~1
3 -> 2.50 - 3.49 -> roundrange is ~1
4 -> 3.50 - 4.00 -> roundrange is ~0.5countArray = [0,0,0,0,0]; for "_i" from 1 to 10000 do { number = (round random 4); countArray set [number,(countArray select number) + 1]; }; // 0 1 2 3 4 // countArray example result -> [1287,2517,2495,2460,1241]
I deleted your note. What you observed is random command distribution and not round doings. Killzone_Kid (talk) 16:20, 28 August 2015 (CEST)