This could be "Who's Cribbing" by Jack Lewis, which can be read here.
It's written as a series of letters between a prospective writer and a publisher, and starts thus:
Mr. Jack Lewis
90-26 219 St.
Queens Village, N.Y.
Dear Mr. Lewis:
We are returning your manuscript "The Ninth Dimension." At first glance, I had figured it a story well worthy of publication. Why wouldn't I? So did the editors of Comic Tales back in 1934 when the story was first published.
As you no doubt know, it was the great Todd Thromberry who wrote the story you tried to pass off on us as an original. Let me give you a word of caution concerning the penalties resulting from plagiarism.
Sincerely,
Doyle P. Gates
Science Fiction Editor
Deep Space Magazine
Lewis then complains that he's never heard of Thromberry, but the editor explains that it's a word-for-word copy:
By "copy," I do not mean rewrite word for word one or more of his works, as you have done. For while you state this has been accidental, surely you must realize that the chance of this phenomenon actually happening is about a million times as great as the occurrence of four pat royal flushes on one deal.
However, it should be noted that this itself is an idea that has occurred, with variations, a number of times. Arthur C. Clarke, for example, wrote "The Longest Science Fiction Story Ever Told" (actually quite short, but 'longest' because it's recursive and infinite) in which the story being plagiarized is the editor's letter about how the story has already been done.