Check out the exercise by Robomind where you use simple instructions to control your own robot.
http://www.code.org/educate
-->
Here is a sample of a simple exercise that is used to test your skill :
# Let the robot draw a square.
# Only use forward(3) and right.
# Use paintWhite for drawing
repeat(4)
{
i = 1
paintWhite
repeatwhile(i<4)
{4>
forward
paintWhite
i=i+1
}
j=1
paintWhite
right
repeatwhile(j<4)
{4>
paintWhite
j=j+1
}
}
Here is a workable solution. Maybe not the best solution but a real one at that.
There are many such fun exercises on the site.
Check it out.
Comments