A student answered exam question with a method she's working on her thesis. What should she do to keep the authorship her own? My friend, a graduate student answered an exam question (in Data Mining field) with a method she's going to propose in her thesis, which has not been published yet as it is still unfinished. The (soon-to-be) thesis itself propose a single new method.

What caused her anxiety:


Her lecturer is currently on a research in data mining too and they are not in the same research group. 
The exam question itself contained a statement like this, "Use whatever method you know of". 


The point is that my friend is afraid that her lecturer may pick that method to incorporate or develop in his research while he wouldn't know that it is actually a part of his student's research. If that happened her thesis would be in jeopardy.

From my previous question in SE, I get that lecturers really rarely mine ideas from students' exams, but my friend is still worried because her thesis is basically proposing that one method.

What could my friend possibly do in this complicated situation and state of mind?
Your friend's concern is pretty far-fetched.  Researchers aren't usually in the habit of mining student exams for research ideas.  Even if the professor was inspired by it, it's quite likely he would want to discuss it with the student anyway, and the thesis issue could be brought up at that time.

But if she is still worried, there's an extremely simple solution: just tell him about it.  Send a short email mentioning that the exam question turned out to be related to her thesis work, and that her answer is based on her research work so far; and that if it's something that interests him, she would be happy to meet and tell him more.  (But it would be a good idea to check with her advisor before that meeting, in case there is some information which is proprietary or confidential or otherwise should not be shared at all.)

Now he knows that it is part of her research, and the feared scenario is averted.