Hi,
How can I create a program that detectes plagarism
lets say we have two files and we want to compare them and at last to have the percentage of smilarity

I am aware of strcmp and compare and I know how to use them it's just the methodology that I should work with to solve this problem that I can't figure out .. please help asap

guidience to the approach is appreciated and if anyone can solve it for me to understand they would save my life :( this is not a homework .. just a preparation for an exam

Recommended Answers

All 5 Replies

Before you write this program you need to think about the problem.

You said you want to " have the percentage of smilarity". You have the
right idea about using strcmp, but its not what you should use. For
this you should use std::string.

So lets talk about what you need to do in order to get the percentage of
similarity between two files. What do you think we need to do ( in
details) in order to get the percentage of similarity?

Before you write this program you need to think about the problem.

You said you want to " have the percentage of smilarity". You have the
right idea about using strcmp, but its not what you should use. For
this you should use std::string.

So lets talk about what you need to do in order to get the percentage of
similarity between two files. What do you think we need to do ( in
details) in order to get the percentage of similarity?

Its complex since I have to compare a word for word then a word for sentence ... if I found that word1==word2 then I'll incremant a counter ... and I'll have another counter for all words then I'll devide those and multiply by 100 ..

>>Its complex since I have to compare a word for word then a word for sentence ... if I found that word1==word2 then I'll incremant a counter ... and I'll have another counter for all words then I'll devide those and multiply by 100 ..

Don't worry about it. You don't need to publish this do you?
So it doesn't matter, for now, if your program is simple. How about
randomly searching for a sequence of words from one file onto another?

I wonder if in a couple of years, some brain-dead doofus will bump this thread with "plz snd me ur plagiarism detection codez" :D ;) :twisted:

commented: Priceless! +1
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.