Question

Which style rule will underline the last item in an ordered list? ol li:last {text-decoration: underline;}...

Which style rule will underline the last item in an ordered list?

  1. ol li:last {text-decoration: underline;}

  2. ol li:last-of-type {text-decoration: underline;}

  3. ol li#last {text-decoration: underline;}

  4. ol li.last-of-type {text-decoration: underline;}

Homework Answers

Answer #1

SOLUTION :

ol li:last-of-type {text-decoration: underline;} is the right answer.

EXPLANATION :

  • last-of-type : matches the last element

EXAMPLE PROGRAM :

<!DOCTYPE html>
<html>
<body>
<head>
<style>
ol li:last-of-type {text-decoration: underline;}
</style>
</head>
<h2>Ordered list</h2>
<ol>
<li>Alpha</li>
<li>Beta</li>
<li>Gamma</li>
</ol>
</body>
</html>

OUTPUT :

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
​ Identify a style rule used to align the table data in the center of the...
​ Identify a style rule used to align the table data in the center of the cell. a. ​table_data { text-align: center; } b. ​td { text-align: center; } c. ​th { <text-align/>: center; } d. ​tdata { text-align: <center/>; } ​ While styling a table for a tablet viewport, the table can be centered on the page significantly by setting the left and right margins to a value of _____. a. ​center b. ​1 c. ​auto d. ​0 ​...
Open the debug3-4.css file. The body element should have a width that is 90% of the...
Open the debug3-4.css file. The body element should have a width that is 90% of the width of the browser window ranging from a minimum of 600 pixels up to a maximum of 1024 pixels. Fix the syntax errors in the body style rule that defines the width of the web page. The style rule for the body element sets up a grid layout for the page. However, there are several errors in defining the grid areas, grid columns, and...
in python For a list of 100 items, the index of the last item is: (please...
in python For a list of 100 items, the index of the last item is: (please don't use negative indexing here...) Answer:
Which of the following style rules will center the text of all h1 through h6 headings...
Which of the following style rules will center the text of all h1 through h6 headings with the text displayed at normal weight? h1 - h6 {    text-align: center;    weight: normal; } h1, h2, h3, h4, h5, h6 {    align: center;    weight: normal; } h1, h2, h3, h4, h5, h6 {    text-align: center;    font-weight: normal; } h1 - h6 {    text-align: center;    font-weight: normal; }
From the list of structures that you ordered for hearing, which structure is the receptor that...
From the list of structures that you ordered for hearing, which structure is the receptor that changes sound energy to action potential?
The Item List can be accessed from which section of the QUICKBOOKS Home Page? 1. banking...
The Item List can be accessed from which section of the QUICKBOOKS Home Page? 1. banking 2. customer 3. vendor 4. company
Look at the list of ingredients on an item you have in your home for the...
Look at the list of ingredients on an item you have in your home for the name of a chemical compound that interests you. Please select a compound that has not already been discussed. Using your textbook and the Internet, answer the following questions regarding your compound: What is the name of your compound? What is its chemical formula? What is its molar mass? Show your work. What type of bonding is used in the formation of your compound (ionic...
Write a LISP function REMOVELAST which removes the last element of a given list. For example:...
Write a LISP function REMOVELAST which removes the last element of a given list. For example: (REMOVELAST ‘(A (A B) C)) Returns the list (A (A B)) and (REMOVELAST ‘(A B (C D))) Returns the list (A B)
You must implement a dynamic webpage the provides a basic task-list functionality. In particular, you page...
You must implement a dynamic webpage the provides a basic task-list functionality. In particular, you page should provide a user an interface to add and remove a task as well as mark a task as completed. For this version of the assignment, the tasks will be added directly in the HTML page by manipulating the DOM. Moreover, you should maintain an array that stores task details. Each task comprise of three fields: task-title: which is a one-line description of the...
Question 61 ​The tag for creating a numbered list is ____. a. ​<ol> b. ​<li />...
Question 61 ​The tag for creating a numbered list is ____. a. ​<ol> b. ​<li /> c. ​<ul> d. ​<nl> 1 points Question 62 ​The term for a collection of website files stored on a web server is ____. a. ​active website b. ​local website c. ​remote website d. ​plug-in website 1 points Question 63 ​The text editor installed with Windows is called ____. a. ​web pad b. ​MS Sketch c. ​Notebook d. ​Notepad 1 points Question 64 ​The text...
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT