Picking random if statements in a for loop

Let’s say I have five if statements, only one of them is the correct if statement, What I want to do is make a loop that has pick a if statement at random check if it’s the right one and if it’s not then pick another one until it finds the correct If statement.

I am not sure I understand your question. Could you paste the code example here?