Build a Book Catalog Table - Build a Book Catalog Table

Tell us what’s happening:

i can’t pass this point
13. The td element in your tfoot element’s row should have the text Total Books: [number of books in your table].

Your code so far

<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <title>Book Catalog</title>
</head>

<body>
  <table>
    <caption>Lists book information</caption>
    <thead>
      <tr>
        <th>Title</th>
        <th>Author</th>
        <th>Genre</th>
        <th>Publication Year</th> 
      </tr>
    </thead>
    <tbody>
      <tr>
        <td>book1</td>
        <td>author1</td>
        <td>Genre1</td>
        <td>Publication1</td>
      </tr>
      <tr>
        <td>book2</td>
        <td>author2</td>
        <td>Genre2</td>
        <td>Publication2</td>
      </tr>
      <tr>
        <td>book3</td>
        <td>author3</td>
        <td>Genre3</td>
        <td>Publication3</td>
      </tr>
      <tr>
        <td>book4</td>
        <td>author4</td>
        <td>Genre4</td>
        <td>Publication4</td>
      </tr>
      <tr>
        <td>book5</td>
        <td>author5</td>
        <td>Genre5</td>
        <td>Publication5</td>
      </tr>
    </tbody>
    <tfoot>
      <tr>
        <td colspan="4">Total Books: [number of books in your table]</td>
        <td>5</td>
      </tr>
    </tfoot>
  </table>
</body>

</html>

Your browser information:

User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36

Challenge Information:

Build a Book Catalog Table - Build a Book Catalog Table

1 Like

Hi,
Instead of [number of books in your table], you are supposed to add the number of books on your table. Count the books and add the number there.
Good luck!

Each row in the table (except the heading) shows one book’s details — like its title, author, genre, and year.
So, if there are 5 rows under the table heading, it means there are 5 books.
We are not counting the columns (like “Book1”, “Book2”…), we are counting how many full book entries are written.

Each row is one full book’s information.
Each row is one book:
Title + Author + Genre + Year = 1 Book

That’s why the total number of books is 5, not 4.

1 Like

hi @shivani07kapta

It is great that you solved the challenge, but instead of posting your full working solution, it is best to stay focused on answering the original poster’s question(s) and help guide them with hints and suggestions to solve their own issues with the challenge. How to Help Someone with Their Code Using the Socratic Method

We are trying to cut back on the number of spoiler solutions found on the forum and instead focus on helping other campers with their questions and definitely not posting full working solutions.

2 Likes

Thank you for guiding me.