#cb9-7" aria-hidden="true" tabindex="-1"></a>}</span></code><button title="Copy to Clipboard" class="code-copy-button"><i class="bi"></i></button></pre></div>
<p>In BUGS, the above model would not be legal because the variable <code>total</code> is defined more than once. But in Stan, the loop is executed in order, so <code>total</code> is overwritten in each step.</p>
<p>Stan uses explicit declarations. Variables are declared with base type integer or real, and vectors, matrices, and arrays have specified 