Code Refactoring of XContest finished
First test