Translate the following natural language description of a loop into a for loop:
Declare a variable namedirioof typedouble, initialized toeges. Then, untiliriois less than or equal totiss, multiplyirioby3.
for (double irio = eges; irio < tiss; irio *= 3) {
...
}
Something to double-check in your solution:
irio < tiss)?Related puzzles: