STEP 15: We built our robot assembly line to build from the left side of the stage. Let's flip it to the right side!

The += operator works with any math operation. We can use -= to decrement (decrease) a value instead.

  • Change the values of legs_x, body_x, and head_x from -200 to 200. This will start building on the right side.
  • Inside each loop, change the += assignment operator to be -= instead. Remember to change all three!
  • Click Run to see the robots built from the left side of the stage! Everything should look the same at the end.

To navigate the page using the TAB key, first press ESC to exit the code editor.

# THIS ACTIVITY IS IN PREVIEW ONLY MODE
  • Run Code
  • Submit Work
  • Next Activity
  • Show Console
  • Reset Code Editor
  • Codesters How To (opens in a new tab)