Skip to content

Latest commit

 

History

History
43 lines (35 loc) · 1.29 KB

3_WorkingWithText.md

File metadata and controls

43 lines (35 loc) · 1.29 KB

#3

  1. How do you create a paragraph in HTML? Use the <p> element to create a paragraph. html Code: <p>This is a paragraph.</p>

  2. How do u create heading in HTML ? Use the <h1> to <h6> elements for headings, where <h1> is the largest and <h6> is the smallest. Code: <h1>This is a Heading 1</h1>

  3. What element should you use to make text bold and important? Use the <strong> element to make text bold and indicate importance. Code: <strong>This is bold text.`````

  4. What element should you use to make text italicized to add emphasis to it? Use the <em> element to make text italicized and add emphasis. Code: <em> This is italicized text </em>

  5. What relationship does an element have with any nested elements within it? The outer element is the parent, and the inner elements are the children. The relationship is hierarchical. Code:

<div>
  <p>This paragraph is a child of the div.</p>
</div>
  1. What relationship do two elements have if they are at the same level of nesting? If two elements are at the same level of nesting, they are siblings. Code:
 <div>
  <p>This is a sibling paragraph.</p>
  <p>Another sibling paragraph.</p>
</div>  
  1. How do you create HTML comments? <!-- This is a comment in HTML -->