Code we use - Preview

typescript
const rules = [
  {
    condition: totalPostCharactersCount < 750,
    apply: () => {
      penalty += 1;
    },
  },
  {
    // Applies a penalty if the reading time exceeds 15 minutes calculated by ${AVERAGE_READING_SPEED}
    condition: totalPostCharactersCount > 15_000,
    apply: () => {
      penalty += Math.round((totalPostCharactersCount - 10_000) * 0.003);
    },
  },
];

Write a text with a length between 750 and 15,000 characters. A text of 15,000 characters is equivalent to 10 minutes of reading, assuming an average reading speed of 250 words per minute.