Quiz Html Fundamentals

HTML Fundamentals

Describe the purpose of the <!DOCTYPE> declaration.

Refers the browser to another page upon loading.
Informs the browser of the document's HTML version.
Signals a comment in the code.
None of the above; this is not a valid HTML element.

Describe the purpose of the <html> element.

Tells the browser to ask the server for another HTML page.
Comments out the HTML code in between.
Denotes the starting and ending points of the HTML document.
None of the above.

Describe the purpose of the <head> element.

Denotes the section of the HTML document that contains the title, metadata, and other browser related script, css, and shortcut icon links.
Tells the browser that the start of the document is coming.
Used to denote the heading bar that appears at the top of page layouts usually containing main page navigation.
None of the above.

Describe the purpose of the <body> element.

Denotes the invisible parts of the page for search engines.
Tells the browser to remove spacing around the elements within.
Tells the browser to add scrollbars to the content below.
Denotes the section of the HTML document that contains all of the visible page content such as images, text, links, and page layout.

Describe the purpose of the <title> element.

Denotes the part of the page with the largest heading over 18px.
Denotes the part of the page where the main navigation will sit.
Gives a title to the website that will be used to style all pages under that style.
Denotes the page's main title. This appears in the tab at the top of the browser and is important to search engines.

Describe the purpose of the <h1> element.

Tells search engines that the enclosed content is the most important on the page.
Denotes a level 1 heading.
Suggests that the content is hot.
Both A and B.

Describe the purpose of the <p> element.

Contains readable text content.
Denotes a paragraph of text.
Allows spatial relationships between the paragraph and other elements above and below.
All of the above.

Describe the purpose of the <ul> element.

Denotes an unordered list of items.
Tells the browser to underline the text inside.
Tells the browser to highlight the text inside.
None of the above.

Describe the purpose of the <ol> element.

Tells the browser to overline the text inside.
Adds an outline around the element.
Denotes an ordered list of items.
None of the above.

Describe the purpose of the <li> element.

Denotes a listen element that plays a sound.
Creates list items to exist inside either <ol> or <ul> parent elements.
Tells the browser to italicize the text.
None of the above.

Describe the purpose of the <img> element.

Denotes an image to be loaded inside the document.
Denotes an imaginary line inside the document used for planning.
Its alt attribute describes the content to screen readers and search engines.
Both A and C.

Describe the purpose of the <a> element.

Sets the browser to alarm an alert sound.
Denotes an anchor link for the purpose of navigating between pages.
Denotes an automatic closing of the page.
None of the above.

It is the best practice to group all HTML files (and other subfolders) for a website into a single parent folder.

TRUE
FALSE

It is impossible to validate HTML to check if it is written correctly.

TRUE
FALSE

The <th> element denotes a heading cell within a table.

TRUE
FALSE

The file name of the HTML document for your website's home page (the first page you want to load) must be called:

index.html
homepage.htm
anything.html
None of the above.

Which of the following code snippets demonstrates an HTML comment?

// This is a comment in HTML
/* This is a comment in HTML */
<!-- This is a comment in HTML -->
# this is a comment in HTML

Identify the line of code (by line number) that has an error from the following example:

01    <h2>Grocery List</h2>
02    <ul>
03      <li>Apples</li>
04      <li>Oranges</li>
05      <li>Pears</li>
06    </ol>

01
02
03
04
05
06

Identify the line of code (by line number) that has an error from the following example:

01    <h2 Directions</h2>
02    <ol>
03      <li>Go to north on Route 42.</li>
04      <li>Make at left at Dawsons Hwy.</li>
05      <li>Turn left at Smith Rd.</li>
06    </ol>

01
02
03
04
05
06

View HTML Fundamentals Quiz on Learn.co and start learning to code for free.

Unlock your future in tech
Learn to code.

Learn about Flatiron School's Mission

With a new take on education that falls somewhere between self-taught prodigy and four-year computer science degree, the Flatiron School promises to turn students with little programming experience into developers.

In the six months since the Manhattan coding school was acquired by WeWork, it has spawned locations in Washington, D.C., Brooklyn, and London. Now, WeWork is opening a fourth Flatiron School location, this time in Houston.

Adam Enbar, Flatiron School's cofounder, believes now is the time to grow. "How the world is changing has impacted working and learning in very similar ways. We think education fundamentally is about one thing: enabling people to pursue a better life."

Learn. Love. Code.
Students come to Flatiron School to change their lives. Join our driven community of career-changers and master the skills you need to become a software engineer or a data scientist.
Find Us