Select not more than a specific number

Hello. Am asking 8 questions with yes/no responses. I want to put constraint such that you can select not more than 5 yes. Kindly help. Here is the form
my juice.xlsx (11.1 KB)

Please see the attached form with edits and test if it works for you. I have also included an example in the form using a select_multiple and the count-selected() function. Scroll down on https://docs.getodk.org/form-operators-functions/#selected for details on the function.

my juice - edits.xlsx (11.5 KB)

@danbjoseph Thanks alot. This is what I was looking for.