Ranked by One Metric, Scored by Another

Norms & DistanceMedium+20 XP+20

Ranked by One Metric, Scored by Another

A streaming service recommends shows by finding the single most similar user to you and copying what that user watched.

Each user is described by four features. Here is the query user QQQ and the three candidate neighbours:

Userf1f_1f1​: ratings per weekf2f_2f2​: distinct genresf3f_3f3​: minutes watched per dayf4f_4f4​: sessions per week
Q (query)1054020
A1264540
B162558
C273024

The four features are measured in wildly different units, so before any distance is computed each coordinate is divided by that feature's typical spread:

FeatureTypical spread sjs_jsj​
f1f_1f1​2
f2f_2f2​1
f3f_3f3​5
f4f_4f4​4

So every user vector vvv becomes v~\tilde{v}v~ with v~j=vj/sj\tilde{v}_j = v_j / s_jv~j​=vj​/sj​, and all distances below are measured on the scaled vectors.

The system does two different things with two different norms:

  1. Retrieval. The index ranks the candidates by Manhattan (L1L_1L1​) distance from the query — it is far cheaper to compute at scale — and returns the single closest candidate.
  2. Scoring. The number shown next to the recommendation is that returned neighbour's Euclidean (L2L_2L2​) distance from the query.

What number does the system display?

Give your answer rounded to two decimal places — for example 1.23.

Bird's Flight vs. Taxi Route

Two ways to measure the distance between the same two points on a city grid.

AB
A bird flies straight from A to B: distance = 7.62 blocks. This is Euclidean distance.

Hints

Solve it to unlock the solution

Once you get it right, the reasoning behind the answer shows up here.

units