5 Replies
Jerry Beaucaire

My idea would be to first create a T/F question for the actual assessment recording, "Did they get the codes in the correct order?"

This question is actually unseen by the user.

Create a trigger on this slide that will SUBMIT the interaction automatically if the FALSE button is ever selected.  TRUE is the correct answer, however.

On a layer build your question using the desired elements, including your own Submit button which triggers some text evaluations.

1. If code1 = "sun", set T/F = TRUE, else set T/F = False (trigger actually selects the false button)

2. If T/F = True, then: If code2 = "mon" set T/F = TRUE, else set T/F = False

3. If T/F = True, then if code3= "tue" or "wed" or "thu", set T/F = TRUE, else set T/F = False

4. If T/F = True, then if code4= "tue" or "wed" or "thu", set T/F = TRUE, else set T/F = False

5. If T/F = True, then if code5= "tue" or "wed" or "thu", set T/F = TRUE, else set T/F = False

Finally a trigger to SUBMIT the interaction.  If this last trigger ever occurs, it means they got the whole thing correct and the base question is still set to TRUE, so they win.  

If any of the steps 1-5 ever result in FALSE, then the trigger you set on the base question would automatically occur and submit as FALSE and they would fail.

-----------

Not that simple, but I've done things like this in the past to give me some flexibility with what is actually going on in the question, the hidden question just being a T/F test.

Walt Hamilton

What Jerry gives you is a good start, but I think you need some additional triggers to test that tue exists as an answer, that wed exists as an answer, and that thu exists as an answer. Otherwise, entering tue for 3, 4, and 5 will result in getting the question correct, without using wed or thu.

I envision three T/F variables, tuePresent, wedPresent, and thuPresent, all set to an initial value of F.

Then these triggers:

6. If code 3 = "tue", set tuePresent = True.

7. If code 3 = "wed", set wedPresent = True

8. If code 3 = "thu", set thuPresent = True.

Repeat all three for  code 4, and 5.

9.I f T/F = True, then if tuePresent = True AND wedPresent = True, AND thuPresent = True, set T/F = TRUE, else set T/F = False

Jerry's triggers will allow them to be entered in any order, while these will require that all three are used.

Jerry Beaucaire

Good points Walt/Michael.  A way to solve these issues and still get it in one test, perhaps something like:

3. If T/F = True, then if code3= "tue" or "wed" or "thu", AND code3 ≠ code4 AND code3 ≠ code5, set T/F = TRUE, else set T/F = False

4. If T/F = True, then if code4= "tue" or "wed" or "thu", AND code4 ≠ code3 AND code4 ≠ code5, set T/F = TRUE, else set T/F = False

5. If T/F = True, then if code5= "tue" or "wed" or "thu", AND code5 ≠ code3 AND code5 ≠ code4, set T/F = TRUE, else set T/F = False

That should get the effect desired without more variables.  Blank won't work, and this ensures those last variables can only be used once.

Math Notermans

I thought it might be simpler to solve using Javascript. If it is a simple solution i am not sure, but this is my approach for this anyway.

https://360.articulate.com/review/content/6a563e59-6fa5-4e46-880b-84306e82c324/review

This is the code that finally checks if all is correct or not on Submit.

let player = GetPlayer();

let code1 = player.GetVar("inputCode1");
let code2 = player.GetVar("inputCode2");
let code3 = player.GetVar("inputCode3");
let code4 = player.GetVar("inputCode4");
let code5 = player.GetVar("inputCode5");

let inputArr = player.GetVar("inputArray");

let showLayer = player.GetVar("showLayer");

//Here we check all entries
let code1Correct = code1 == "sun" ? true : false;
let code2Correct = code2 == "mon" ? true : false;
let code3Correct = inputArr.includes("tue");
let code4Correct = inputArr.includes("wed");
let code5Correct = inputArr.includes("thu");

//if all are true... the answers are correct
if(code1Correct && code2Correct && code3Correct && code4Correct && code5Correct){
player.SetVar("showLayer",1);
}else{
player.SetVar("showLayer",2);
}


Storyline added.