If you encounter "your idea" in a source...
Don’t pretend that you never encountered the source; but don’t panic either. If it’s your major idea and you’re near the end of work on the paper, finish writing your argument as you have conceived it. Then look closely at the source in question: chances are that its idea isn't exactly the same as yours, that you have a slightly different emphasis or slant, or that you are considering somewhat different topics and evidence. In this case you can either mention and cite the source in the course of your argument (“my contention, like Ann Harrison’s, is that. . .” or “I share Ann Harrison’s view that...”), but stress the differences in your account, what you have noticed that Harrison hasn’t. Or you can go back and recast your argument slightly, to make it distinct from the source’s. If the argument in the source really is the same as yours, and you are in the midst of a long paper, go to your instructor, who may be able to suggest a slightly different direction for your paper. If you aren’t writing a big paper, and haven’t time to recast, use a note of acknowledgment:
12. In the final stages of writing this paper I discovered Ann Harrison’s article “Echo and Her Medieval Sisters,” Centennial Review 26.4 (Fall 1982), 326–340, which comes to the same conclusion. See pp. 331–2.
Don’t try to use such a note to cover plagiarism. Your instructor will know from your paper whether you had your own, well-developed ideas before reading the source, and may ask you to produce your rough notes or drafts. (To be safe, always hold on to your notes and drafts until a paper has been returned.)