Journal of Jilin University(Information Science Ed ›› 2015, Vol. 33 ›› Issue (1): 99-104.

Previous Articles     Next Articles

Research on Similarity Measure for AST-Based Program Codes

ZHU Bo, ZHENG Hong, SUN Linlin, YANG Youxing   

  1. School of Computer Science and Engineering, Changchun University of Technology, Changchun 130012, China
  • Received:2014-08-27 Online:2015-01-24 Published:2015-03-20

Abstract:

In order to solve the program code similarity detection measurement which ignores the program semantics and the invalid measurement, we present
 an AST(Abstract Syntax Tree) based on the program code similarity measure method. Through the pretreatment redundancy removal in AST generation and the lexical grammar analysis, get the corresponding AST; and then according to the adaptive threshold method,using the AST traversal which include the sequence and process attributes to take the similarity calculation;finally,determine whether plagiarism and generate the test report.The experimental results show that this method can effectively detect a variety of plagiarism java code.

Key words: similarity measurement, abstract syntax tree (AST), similarity, adaptive threshold

CLC Number: 

  • TP311