CREATE TABLE "season_3_1996_1997" (
  "series_num" real,
  "season_num" real,
  "title" text,
  "directed_by" text,
  "original_air_date" text,
  "production_code" text
);

Question: What is the title of the episode with a production code of K1504?
SQL: SELECT "title" FROM "season_3_1996_1997" WHERE "production_code"='k1504';

Question: What is the average of the Series #s that were directed by Matthew Penn?
SQL: SELECT AVG("series_num") FROM "season_3_1996_1997" WHERE "directed_by"='matthew penn';

Question: How many episodes did Matthew Penn direct before season 22?
SQL: SELECT COUNT("series_num") FROM "season_3_1996_1997" WHERE "season_num"<22 AND "directed_by"='matthew penn';