add an additional function, 'check duplicate' and some bug fix.
Merge branch 'master' of https://github.com/umworkma/Comp4350