Spooky Sale: 10% off Premium yearly · $118.80 for the first year · until Nov 6Get it

Deep-ML
Learn
Problems1,200+ hands-on ML problemsLearning PathA guided route through the fundamentalsLabsInteractive labs on real techniquesProjectsBuild a GPT, an RL agent, CUDA kernelsCollectionsCurated problem sets and videosMathPen-and-paper math for MLIntuitionInvent the idea behind the formula yourselfPlaylistsYour own problem lists, shareableStudy AssistantAn AI teacher that knows your progress
Interview Prep
Compete
ContestsFresh problem sets, ranked liveLeaderboardWhere you stand, globallyBuddiesSolve with a friend: streaks, a weekly board, chat
Discuss
Deep-Path
Premium
      Intuition
      14 of 130

      Score every movie at once

      A streaming app lists its movies as a table, movies: one row per movie, saying how much of each genre it has. taste says how much you like each genre, as in Match score. Write scores(movies, taste): how much you’ll enjoy each movie, one score per movie, so the app can show it under every poster.

      A streaming app’s catalogue is a table: one row per movie, how much of each genre it has. Your taste sits on top, the same genres in the same order. Adding the whole table up gives one number, and one number can’t pick a movie. The goal is a score for every movie, beside its own row, like the bars it ends on. Your scores(movies, taste) gives them all at once.

      Your taste on top. Below, the catalogue: one row per movie, its genres.you likeaction+2romance−1horror0comedy+1Laser Ninjas3001Paris, Again0301The Basement1030Wedding Crash1203Ghost Prom0122
      Your functionscores(movies, taste)
      moviesthe catalogue (a numpy array), one row per movie: how much of each genre it hase.g. [[3, 0, 0, 1], [0, 3, 0, 1], [1, 2, 0, 3]]
      tastehow much you like each genre (a numpy array), the same genres in the same ordere.g. [2, −1, 0, 1]
      returnshow much you'll enjoy each movie: one score per movie
      solution.pyLoading Python
      Sign in for an AI hint
      ← Match scoreEvery user, every movie →