How plagiarism detector is coded in python