FunctionRacerProblemsRace

Latest Price

MediumSQLSQLite

prices holds closing prices: one row per symbol and day, and not every symbol has a price on every day. Return each symbol once with close: its price on the latest day it has one. Rows may come in any order.

Example 1

prices
symboldayclose
AAPL2026-01-05190.5
AAPL2026-01-07188.0
MSFT2026-01-06410.0
MSFT2026-01-02415.25
returns
symbolclose
AAPL188.0
MSFT410.0

Constraints

Race itor take your time

Write it in your browser, against the clock. The model query, with a note on each piece of it, comes after.

More SQL problems