cc3.12/cis1.0/robotics
fall 2007
assignment II part 1
INFORMATION
- This assignment covers the material from unit II in our
syllabus: Algorithms and Computer Languages.
- You may find it helpful to read ch 2 and ch 8 in
the Reed text in order to complete this assignment.
- You may also find it helpful to refer to the on-line tutorials
linked on the class web page.
- You can also refer to the lecture notes from Mon Sep 17, posted
on the "syllabus" portion of the class web page
- This assignment (both parts) is worth 7 points, or 7% of your term grade.
INSTRUCTIONS
- For this assignment, you will create several HTML files in
Notepad.
- Type your name in the files and your email address as
comments.
- Save your work!!!
BEFORE YOU LEAVE THE LAB, make sure that you save your work
(both HTML files and any images files you use) by storing them
on a USB flash drive or by mailing them to yourself.
- When you are completely finished with all the steps, zip
all your files together and email the zip file to me as an
attachment.
I will explain how to do this in the lab session.
- The subject line of your email should say:
cc3.12 hwII
- My email address is: sklar@sci.brooklyn.cuny.edu.
THE ASSIGNMENT IS DUE ON MONDAY OCTOBER 1, 2007.
BE SURE TO ASK IN THE LAB IF YOU NEED HELP WITH ANY STEPS!!!!
PART I. CREATE FIRST HTML FILE.
Step 1. Get started.
(1 point)
- Start up Notepad.
In the file, you will write HTML code to do the things
listed below.
- Set the title of the web page (the title is what is
displayed in the heading bar of the browser, not in the body).
- Set the background color of the page to something
other than the default (usually white).
You can do this using the body tag and the
bgcolor parameter, like this:
<body bgcolor="yellow">
which sets the background color in the browser to yellow.
- Set the text color of the page to something other
than the default (usually black).
- Display text welcoming the user to your web page
(e.g., "Welcome to Prof Sklar's home page!")
- Save the file and name it with your last name followed by
the .html extension.
For example, my file would be called sklar.html.
Be sure to tell Notepad not to put the ".txt" extension after ".html"!
- Try opening the file with a browser and see what it looks
like.
If any of the elements above don't work, go back into the
Notepad window, and edit the file to fix them.
Then reload the file in your browser.
Keep doing this until everything looks just perfect :-)
Step 2. Add a list.
(0.5 points)
- Now add HTML code that displays an unordered list of
five of your favorite foods.
Hint: use the <ul>
tag.
- Be sure to make the page user-friendly and by putting in
explanatory text telling what the list is
(e.g., "Here is a list of my five of my favorite things to
eat:").
Step 3. Create second HTML file.
(1 point)
- Open a new file in Notepad.
- In this file, put HTML code that displays a recipe for one of your
five favorite foods.
The recipe should contain step-by-step, numbered, detailed
instructions for how to prepare the recipe.
For example:
- Preheat the oven to 350o.
- Take the butter out of the refridgerator to
soften.
- Measure out 2 1/4 cups of flour and place it in
the sifter.
- etc.
Hint: use the <ol>
tag.
- Back in the first file, make a link (i.e., a href=...)
to the second file, so that when you click on the list item
for which the second file contains the recipe, you go to that
recipe page.
- When you save this file, name it with your last name, followed by
the number 2, followed by the .html extension.
For example, mine is: sklar2.html.
Step 4. Add a table.
(1 point)
- As part of the recipe (second) file, write HTML code that uses a
table to list the ingredients.
The table should have at least 2 columns: one for the amount and one
for the name of each ingredient.
I will explain in the lab how to make tables.
Step 5. Add an image.
(0.5 points)
- In either file (first or second), write HTML code that displays a
picture (image) in the page.
This can either be a picture of yourself or of the recipe, or anything
else appropriate.
You can download a picture from the internet.
PART II.
Part II (worth 3 more points) will be available in the lab on
Wednesday September 24.