You can just md5sum the .cpp file and transform it to uppercase.