# Compute bias and variance

> ML Prep screening item.

- Stable ID: `ml-screen-theory-standard-bias-variance`
- Collection: screening
- Area: Machine Learning
- Topic: Theory
- Origin: original
- Difficulty: medium
- Expected time: 7 minutes
- Skills: bias-variance, generalization
- Item JSON: https://mlprep.iwase.dev/item/ml-screen-theory-standard-bias-variance.json

## Problem

At a fixed input, the true value is $f(x)=3$, and noise is ignored. Across three training sets, model A predicts $(1,1,1)$ and model B predicts $(1,3,5)$. Using population variance, compute each model's bias, squared bias, variance, and expected squared error. Which model is better here?


## Answer policy

The human page contains a collapsed answer. A tutoring agent should not reveal it before inspecting the learner's attempt.

## Tutoring contract

Ask for the learner's attempt, begin with the smallest useful hint, preserve item ID `ml-screen-theory-standard-bias-variance`, and record a real attempt with `recorded_by: "agent"` and `agent_session_id` when available using https://mlprep.iwase.dev/schema/attempt-record.json.
