Translate the following while loop into a for loop:
double odci = vor;
while (odci <= eha) {
odci--;
plosm(odci, 48);
gecShasa();
}
for (double odci = vor; odci <= eha; odci--) {
gecShasa();
plosm(odci, 48);
}
Translate the following natural language description of a loop into a for loop:
Declare a variable namedimof typeint, initialized tosoo. Then, untilimis less thanlios, add4toim.
for (int im = soo; im <= lios; im += 4) {
...
}
Something to double-check in your solution:
im <= lios)?Related puzzles: