Set the font-size for Multiple Heading Elements error

Tell us what’s happening:
Describe your issue in detail here.
I am currently on this challenge and have the correct code for it but I am still getting errors on all code?

   **Your code so far**

<style>
h1 {font-size: 68px;}
h2 {font-size: 52px;}
h3 {font-size: 40px;}
h4 {font-size: 32px;}
h5 {font-size: 21px;}
h6 {font-size: 14px;}
</style>
<h1>This is h1 text</h1>
<h2>This is h2 text</h2>
<h3>This is h3 text</h3>
<h4>This is h4 text</h4>
<h5>This is h5 text</h5>
<h6>This is h6 text</h6>
   **Your browser information:**

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/97.0.4692.71 Safari/537.36

Challenge: Set the font-size for Multiple Heading Elements

Link to the challenge:

i used ur code,and it works perfectly

I also used your code and it worked fine. What is the error you’re receiving?

maybe u should remove ; sign.its not an object
do it;like this h1{font-size:68px}

In CSS, you need to use the semicolon :wink:

You are not the first one to encounter this issue recently, which browser do you use?

@yoshiyoshida64

The code you have shared works on my end. Please ensure that you have disabled any extensions that interface with the freeCodeCamp website (such as Dark Mode and Ad Blocker), and set your browser zoom level to 100%. Both of these factors can cause tests to fail erroneously.

@LucLH While yes, it’s good practice, you dont need the semicolon if you only have one item, or it’s the last item. Source: Syntax - CSS: Cascading Style Sheets | MDN

This I didn’t know thanks. After, they say it too, it is a good practice and for me it should always be here. But if it works it works :slightly_smiling_face:

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.