Introduction To Programming
10-152-310

Learning Plan 2 : Variables and Data Types

Student

  • Name:
  • Section:
  • Email:

Lab Steps

  • Open this file in your browser and Microsoft Visual Studio
  • Add your name, section, and email
  • Add some JavaScript to the coding area that recreates each of the following blocks of output. Use only one document.write() for each of the outputs. Each output has to be exactly the same as these blocks, including any quotes. You can have just one output block that contains all of the lines.
    There's a single quote in this string.
    You'd better not say, "Hey".
    "There's a boy who's shouting, "Hey" too loud."
    This is a tricky
    one
    How'd I do it with just 
    one document.write()?
  • Remember, you can have only four (4) document.write() statements in the entire lab.

Your Output

			
        

What You Did

You practice making string variable and displaying them. You had to use some tricky use of escape characters, too.