All fools are poets; this the Prefect feels; and he is merely guilty of a non distributio medii in thence inferring that all poets are fools.
Dupin makes this statement during his explanation to the Narrator of how he solved the crime and why the prefect could not. One important flaw in the prefect’s thought process is his underestimating Minister D–– simply because he’s a poet, when in reality he, like Dupin, is both poet and mathematician. Here, Dupin shows the prefect’s reasoning is even more flawed because the prefect has committed a logical fallacy by assuming that all poets are fools. Apparently, the prefect cannot even use mathematical reasoning correctly.
As poet and mathematician, he would reason well; as poet, profoundly; as mere mathematician, he could not have reasoned at all, and thus would have been at the mercy of the prefect.
This quotation comes from Dupin’s explanation of the case and the flaws in the prefect’s reasoning. Dupin here explains how Minister D–– having the poetry in him to enhance his mathematical reasoning allows him to outwit the prefect. The prefect would have been able to catch someone with mere mathematical reasoning because a mathematically minded thief would be bound by conventional logical rules. Because Minister D–– is also creative, he can understand that the logical place to hide the letter would be somewhere very hidden, and therefore those logical places are exactly where the police will look.