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 | |
Units: | US Customary | Metric |
Background: |
![]() |
|
|
|
|
|
|
|
|
|
/* Code generated by RoboBlockly v2.0 */ #include <linkbot.h> double H; double W; double L; CLinkbotI robot; double radius = 1.75; robot.traceColor("green", 3); H = 12.3; W = 8.4; L = 5.59; // set the %.#lf in printf() for 3 digits after the decimal point for double type robot.driveDistance(sqrt((H * H + W * W) + L * L), radius);
Problem Statement: The blue spider just made a web strand going from corner A of a cardboard box to corner D. It now needs to crawl back up to the top. Knowing that the dimension of the box is H x L x W = 12.3" x 8.4" x 5.59", calculate the required traveled distance of the spider and drive the linkbot along the web strand path using driveDistace(). Round to 3 decimals point - tip: to avoid precision error, don't round until the end. |
||||||||||||
|
||||||||||||