Strings & Loops: Let's write your name using a random font for each letter! First, let's set everything up.

  • From the LOGIC tab and toolkit, drag Loop through String to the bottom of the program.
  • Change the string "word" to the input variable name. That will loop through each letter of the user's name!
  • From add Random Choice indented in the loop. Change my_list to fonts.
  • Change my_var to rand_font. We now get a new random font for each letter in the name.

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)