Actually, there is a 'trick'... . If you randomize the choices the XForm will turn them into a nodeset, which you can then use the XPath count() function to count how many there are.
Have a play with this form in https://opendatakit.org/xlsform/
count-choices.xls (19.5 KB)
[Update] You can also trigger turning the choices to a nodeset with a simple choice_filter, which avoids randomizing your choices... A simple no-op filter like true()
will suffice
count-choices2.xls (20 KB)
[this trick courtesy @LN ]