How to declare a new variable, name it, and initialize this var to the value of different variable in JavaScript : <p>I need to declare a new variable and name it <strong>r4</strong>. Next, initialize <strong>r4</strong> to the value of variable <strong>r1</strong> incremented by <strong>5</strong>. Finally, print the value of <strong>r4</strong>. </p>

<p><strong>Here is what I have tried so far:</strong></p>

<pre><code>var r4;
r4 = r1;
// trying to use a For Loop. Don't know if it's a right way
  for (r4 = 0; r4 &lt;= r1; r4 = r4 + 5) {
  document.writeln(r4 + "&lt;br/&gt;");
}
</code></pre>

<p><strong>And</strong></p>

<p>Declare a new variable and name it <strong>r5</strong>. Next, initialize the variable to the value of variable <strong>r1</strong> multiplied by <strong>7</strong>. Finally, print the value of <strong>r5</strong>.</p>

<p><strong>Here is what I have tried so far:</strong></p>

<pre><code>var r5;
r5 = r1;
// trying to use a For Loop. Don't know if it's a right way eather
  for (r5 = 0; r5 &lt;= r1; r5 = r5 * 7) {
  document.writeln(r5 + "&lt;br/&gt;");
}
</code></pre>

<p>I know that we might don't even need to use a for loop or any loop But I'm really don't know how to make it work as it requested.</p>

<p>I'm new to JavaScript, so don't judge me hard!</p>

<p>Please, advise me how can I solve this two task?</p>

<p>Thank you!</p>
