Command Palette

Search for a command to run...

Hectal
Phase 15: Accessible Charts
Data Visualization · Exercise 2 of 5 PreviousNext
Intermediate

Write the description from the data

describe(rows) returns a fixed sentence, so the description is wrong as soon as the data changes.

Make it return <busiest day> was the busiest with <rides> rides and <quietest day> the quietest with <rides>. from the rows, and No data. for an empty list. Rides should have a thousands comma (for example 3,992).

What Check tests

  1. The page shows the description of the week
  2. A different week gives a different sentence
  3. An empty list says No data.

Stuck? One hint at a time

The solution unlocks after your first Check. Try first: that is where the learning happens.

Runs in your browser. Your code is saved here.

Your page

Press Run to see the page.

Console

Nothing logged yet.