Typically RETE-based/forward-chaining rules engines execute a rule whenever its condition becomes "newly true". Newly true in this context means that the condition is true and that one of its input variables has been changed since the last time the condition was checked.
In your case, the first rule has no input variables and hence is fired only once. The second rule has two input variables, this.i
and this.Items.Count
. After it is fired first, the second rule modifies this.i
, causing its condition to be rechecked after firing the rule. The condition is then newly true again (repeating then until this.i>=this.Items.Count
).