Appendix A

Answers to Exercises

This appendix covers the answers to each of the exercises at the end of each chapter.

Chapter 1

Exercise 1

Mark up the following list, with inserted and deleted content:

Ricotta pancake ingredients:

  • 1 1/2 3/4 cups ricotta
  • 3/4 cup milk
  • 4 eggs
  • 1 cup plain white flour
  • 1 teaspoon baking powder
  • 75g 50g butter
  • Pinch of salt

Answer

Here is the bulleted list with elements that show which content has been inserted and deleted:

<h1>Ricotta pancake ingredients:</h1>
<ul>
  <li>1 <del>1/2</del><ins>3/4</ins> cups ricotta</li>
  <li>3/4 cup milk</li>
  <li>4 eggs</li>
  <li>1 cup plain <ins>white</ins> flour</li>
  <li>1 teaspoon baking powder</li>
  <li><del>75g</del><ins>50g</ins> butter</li>
  <li>Pinch of salt</li>
</ul>

Chapter 2

Exercise 1

Mark up the following sentence with the relevant presentational elements.

The 1st time the bold man wrote in italics, he emphasized several key words.

Answer

The sentence uses superscript, bold, italic, and emphasized elements.

<p>The 1<sup>st</sup> time the <b>bold</b> man wrote in
 <i>italics</i>, he <em>emphasized</em> several key words.</p>

Exercise 2

You have already created the homepage for the Example Café site that you will build throughout the book. You also created a recipes page. Now you need to create three more pages so that you can continue to build the site in upcoming chapters. Each page should start like the homepage, with a level 1 heading titled Example Café, followed by this paragraph: Welcome to Example Café. ...

Get Beginning HTML and CSS now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.