Module Assembly - Topcoder Competition Engine - Eligibility Questions Validation

Register
Submit a solution
The challenge is finished.

Challenge Overview

Goal

The current functionality for eligibility questions on member registration for SRM is broken and we need to fix it. Currently regardless of the answer to eligibility question the member can register successfully, we need to prevent member registration in case the provided answer doesn't match any of the configured correct answers.

We want to use this functionality to create invitational SRMs, in which users will have to provide an access code, and if the access code doesn't match what is configured they will not be able to register.

Background

We have a SRM Problem Guide (attached in forum) to create official SRM. You will notice it is possible to specify questions that are asked to participants when they register for a match. There are several types of questions, but the one that we are interested in for this challenge is "Elligible".

For each question it is possible to define a number of answers, each answer can be marked as correct or not correct by checking or not the "correct" checkbox when creating each answer.

Also there are different styles of questions: single choice, multiple choice, short answer, long answer. We would like to implement the eligibility functionality for all of these question styles.

Functional Requirements

  • For a question of type Eligible
    • If the question style is single choice: Member should only be allowed to register if one of the correct answer is selected
    • If the question style is multiple choice: Member should only be allowed to register if at least one choice was selected, and all selected choices are correct. The member doesn't have to select ALL correct choices to be able to register successfully.
    • If the question style is short answer: Member should only be allowed to register if the provided answer is a case sensitive full text match to one of the correct answers configured.
    • If the question style is long answer: Member should only be allowed to register if the provided answer is a case sensitive full text match to one of the correct answers configured.

Zero or more eligibility questions may exist for a given registration. If there are no eligibility questions the existing registration process can resume normally. If there are one or more eligibility questions ALL questions must be satisfactorily answered before the registration process can resume.

If the answer/answers provided by the member pass the test above, the regular registration process should resume.

If one or more answers provided by the member do not pass the test above, the following message should be shown: "Based on your answers you are not eligible to participate in this match. If you believe this to be an error please try again or contact your administrator."

Maintain current functionality for all other question types, i.e. if a member provides a correct or incorrect answer to an question that is NOT of Elligible type, the member should be allowed to register successfully.

Technical Requirements

This backend functionality will have to work as well for the applet version of the arena client, for the web arena, it is out of scope for this challenge. But the backend changes should be aware of this.

Arena VM

Before asking your own VM, you need to have a public key on your profile before asking for the VM.

You can find more details on how to generate a key http://apps.topcoder.com/wiki/display/projects/Generate+SSH+Key and how to connect using ithttp://apps.topcoder.com/wiki/display/projects/Connect+Using+SSH+Key.

To use the Arena VM, please follow http://apps.topcoder.com/wiki/display/docs/Competition+Engine+VM+Setup



Final Submission Guidelines

Provide clear documentation of what was changed, and how the solution support the functional and technical requirements.

ELIGIBLE EVENTS:

2015 topcoder Open

Review style

Final Review

Community Review Board

Approval

User Sign-Off

ID: 30044858