Which Males Rank is the highest one that has Females (%) smaller than 40, and Females Rank smaller than 22?
CREATE TABLE "references" (
  "males_rank" real,
  "females_rank" real,
  "state" text,
  "hiv_awareness_malespct" real,
  "females_pct" real
);
SELECT MAX("males_rank") FROM "references" WHERE "females_pct"<40 AND "females_rank"<22;