Limit the number of times an option can be chosen (within same form)

Is there any way to remove a choice from a list after it has been chosen more than a certain number of times (within the same form)?

For example: at the start of each section the first question is a select_one from a list of locations (A, B, C, D, E), and then the next options are varied based on the choice. Ideally, I would like any location chosen X times to no longer appear.

I have played around with adding integers (eg. A1, A2, A3, B1, B2, etc) and then removing the choice selected but becomes cumbersome as the number of locations increases. I imagine there might be a clever calculation method but can’t work out how to do that…

Any help would be appreciated.

Welcome to the community, @cjw! Could you kindly share some dummy questions and choices so that it would be easy for the community to understand them pictorially?


This is the basic format of what my form will look like. I am comfortable filtering choices, and questions based on the answers to previous questions so haven’t added much detail there. Effectively, if the person has chosen Location A for the first 2 questions, I would like Location A not to appear in the choices after that.

Do you think this is possible? (I might have up to 20 Locations in my final form!)

Thanks!

Can you provide more details, please. What should be restricted if the person choses location A in the 2nd and 4th place or in the 2nd and 3rd place.?

Once a Location has been chosen 2 times in total (irrespective of when it was chosen), it should no longer appear in the list of locations, or alternatively an error message be shown if it is chosen a 3rd time.