### Learning Math and Coding with Robots

 Grid: Tics Lines: Width px Hash Lines: Width px Labels: Font px Trace Lines: Robot 1: Width px Robot 2: Width px Robot 3: Width px Robot 4: Width px
 Axes: x-axis y-axis Show Grid Grid: 24x24 inches 36x36 inches 72x72 inches 96x96 inches 192x192 inches Quad: 4 quadrants 1 quadrant Hardware Units: US Customary Metric
 Background:

#### Robot 1

 Initial Position: ( in, in) Initial Angle: deg Current Position: (0 in, 0 in) Current Angle: 00 deg Wheel Radius: 1.75 in1.625 in2.0 in Track Width: in

#### Robot 2

 Initial Position: ( in, in) Initial Angle: deg Current Position: (4 in, 0 in) Current Angle: 90 deg Wheel Radius: 1.75 in1.625 in2.0 in Track Width: in

#### Robot 3

 Initial Position: ( in, in) Initial Angle: deg Current Position: (8 in, 0 in) Current Angle: 90 deg Wheel Radius: 1.75 in1.625 in2.0 in Track Width: in

#### Robot 4

 Initial Position: ( in, in) Initial Angle: deg Current Position: (12 in, 0 in) Current Angle: 90 deg Wheel Radius: 1.75 in1.625 in2.0 in Track Width: in

Turkey Tail
Problem Statement:

You're making a turkey poster for Thanksgiving, but the turkey's tail is incomplete. Use the robot to draw in the lines sectioning the tails by programming the grid location (x,y) where the robot should begin/stop drawing. Make sure the robot doesn't draw the lines on the rest of the turkey
```/* Code generated by RoboBlockly v2.0 */
/* Problem Statement:
You're making a turkey poster for Thanksgiving, but the
turkey's tail is incomplete. use the robot to draw in the
lines sectioning the tails. Make sure the robot doesn't
draw the lines on the rest of the turkey*/
double angle;
double xi;
double yi;
double xo;
double yo;
double radius = 1.75;
double trackwidth = 3.69;
int count;
int count2;
int count3;

robot.traceColor("#330000", 2);
angle = 0;
xi = 4 * cos(deg2rad(angle));
yi = 4 * sin(deg2rad(angle));
xo = 9.5 * cos(deg2rad(angle));
yo = 9.5 * sin(deg2rad(angle));
count = 0;
while(count < 4) {
robot.traceOff();
robot.drivexyTo(xi, yi, radius, trackwidth);
robot.traceOn();
robot.drivexyTo(xo, yo, radius, trackwidth);
robot.traceOff();
robot.drivexyTo(xi, yi, radius, trackwidth);
angle = angle + 20;
xi = 4 * cos(deg2rad(angle));
yi = 4 * sin(deg2rad(angle));
xo = 9.5 * cos(deg2rad(angle));
yo = 9.5 * sin(deg2rad(angle));
count = count + 1;
}
count2 = 0;
while(count2 < 2) {
xi = 7.5 * cos(deg2rad(angle));
yi = 7.5 * sin(deg2rad(angle));
xo = 9.5 * cos(deg2rad(angle));
yo = 9.5 * sin(deg2rad(angle));
angle = angle + 20;
robot.traceOff();
robot.drivexyTo(xi, yi, radius, trackwidth);
robot.traceOn();
robot.drivexyTo(xo, yo, radius, trackwidth);
robot.traceOff();
robot.drivexyTo(xi, yi, radius, trackwidth);
count2 = count2 + 1;
}
count3 = 0;
while(count3 < 4) {
xi = 4 * cos(deg2rad(angle));
yi = 4 * sin(deg2rad(angle));
xo = 9.5 * cos(deg2rad(angle));
yo = 9.5 * sin(deg2rad(angle));
angle = angle + 20;
robot.traceOff();
robot.drivexyTo(xi, yi, radius, trackwidth);
robot.traceOn();
robot.drivexyTo(xo, yo, radius, trackwidth);
robot.traceOff();
robot.drivexyTo(xi, yi, radius, trackwidth);
count3 = count3 + 1;
}
```
```/* Code generated by RoboBlockly v2.0 */
/* Problem Statement:
You're making a turkey poster for Thanksgiving, but the
turkey's tail is incomplete. use the robot to draw in the
lines sectioning the tails. Make sure the robot doesn't
draw the lines on the rest of the turkey*/
double radius = 1.75;
double trackwidth = 3.69;
int count;
int count2;
int count3;

robot.traceColor("#330000", 2);
count = 0;
while(count < 4) {
robot.traceOff();
robot.traceOn();
robot.traceOff();
count = count + 1;
}
count2 = 0;
while(count2 < 2) {
robot.traceOff();
robot.traceOn();
robot.traceOff();
count2 = count2 + 1;
}
count3 = 0;
while(count3 < 4) {
robot.traceOff();
robot.traceOn();