Use the s Tag to Strikethrough Text-1

I’m not sure where to put the word Alphabet as the exercise ask me to. Here is my code:
/
/
/
<style>

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;

}

</style>

<div class=“fullCard”>

<div class=“cardContent”>

<div class=“cardText”>

<h4>Google</h4>

<p><em><s>Google</s> Alphabet was founded by Larry Page and Sergey Brin while they were <u>Ph.D. students</u> at <strong>Stanford University</strong>.</em></p>

</div>

<div class=“cardLinks”>

<a href=“https://en.wikipedia.org/wiki/Larry_Page” target="_blank" class=“links”>Larry Page</a><br><br>

<a href=“https://en.wikipedia.org/wiki/Sergey_Brin” target="_blank" class=“links”>Sergey Brin</a>

</div>

</div>

</div>
/
/
/

You have to read again the exercise:

Wrap the s tag around “Google” inside the h4 tag and then add the word Alphabet beside it, which should not have the strikethrough formatting.

Your code:

<h4>Google</h4>
<p><em><s>Google</s> Alphabet was founded by Larry Page and Sergey Brin while they were <u>Ph.D. students</u> at <strong>Stanford University</strong>.</em></p>

That’s almost correct. You have to do it inside the h4 tag, not p tag :wink:

Have a nice day and good learning!

1 Like