freeCodeCamp Challenge Guide: Use the em Tag to Italicize Text

Use the em Tag to Italicize Text

Relevant Links


Hint 1

Remember that the em tag should only wrap around contents of the p tag but not around the p tag itself.


Solution 1 (Click to Show/Hide)
  h4 {
    text-align: center;
    height: 25px;
  p {
    text-align: justify;
  .links {
    text-align: left;
    color: black;
  .fullCard {
    width: 245px;
    border: 1px solid #ccc;
    border-radius: 5px;
    margin: 10px 5px;
    padding: 4px;
  .cardContent {
    padding: 10px;
  .cardText {
    margin-bottom: 30px;
<div class="fullCard">
  <div class="cardContent">
    <div class="cardText">
      <p><em>Google was founded by Larry Page and Sergey Brin while they were <u>Ph.D. students</u> at <strong>Stanford University</strong>.</em></p>
    <div class="cardLinks">
      <a href="" target="_blank" class="links">Larry Page</a><br><br>
      <a href="" target="_blank" class="links">Sergey Brin</a>

Code Explanation

  • All of the contents within the paragraph element (p), including the period (.), are wrapped in the em tag, causing the text to be displayed in italics.

Relevant Links