How can I solve this programming question for Clara would? Practical 5 Problem 4: Checkerboard with boolean
Fantastic news! We've Found the answer you've been seeking!
Question:
How can I solve this programming question for Clara would?
Practical 5 Problem 4: Checkerboard with boolean
This code that I found in courshero does not work:
class MyClara extends Clara {
int currentposition = 0;
void run() {
while (!treeLeft() && !treeFront()) {
while (!treeFront()) {
if (currentposition%2 == 0) {
putLeaf();
}
move();
++currentposition;
}
}
turnLeft();
move();
turnLeft();
currentposition = 0;
}
}
Related Book For
Posted Date: