What is the mean number of laps when time/retired was spun off and the driver was Nick Heidfeld?
CREATE TABLE "race" (
  "driver" text,
  "constructor" text,
  "laps" real,
  "time_retired" text,
  "grid" real
);
SELECT AVG("laps") FROM "race" WHERE "time_retired"='spun off' AND "driver"='nick heidfeld';