Help comparing two sets of numbers for math app

I need help determining if the two integers the user has chosen are the correct two integers:

Right now, two random integers (which can be the same integer) are chosen from an app data list and the two rows of buttons are generated to include those integers and some incorrect ones.

When the user presses submit, the two values currently selected update two fields of the current user. My question is how to compare the two values of those two fields with the two values that are IntA and IntB? The two sets of numbers need to match exactly, but do not have to be in the same order.

thereâ€™s not enough information here to determine how youâ€™re currently going about what youâ€™re doing and why you canâ€™t just do a conditional of â€śwhen number A is number Bâ€¦â€ť My guess is that you need to set states of an element to hold the values in and then use a conditional to compare them. Or use a â€śwhen condition is trueâ€¦â€ť event.

1 Like

Thanks, that was actually enough to get me going in the right direction. Iâ€™m so fresh that just basic things like realizing how to use states doesnâ€™t occur to me.

This topic was automatically closed after 70 days. New replies are no longer allowed.