# Finding higher frequency among loop question

I have 2 questions as detail below:

Q1. Which of these Energy drink brands have you drink in last 3 months? [Multiple answer]
=> This question is "Select question" and there are 15 brands.

Q2. How often do you drink  [Loop from Q1]  in the past 3 months?
a). 8+ times per week
b). 6-7 times per week
c). 3-5 times per week
d.) Less than 3 can/bottle per week

Question:

1. If Q1 answer more than 1 brand, choose the higher frequency (bottle per week) in Q2
2. If the higher frequency is equal, show those brands and then we can select one of them.

How can I do that?

Create a constructed list with these instructions:

```Begin Unverified Perl
# Settings
my \$frequencyQuestion = 'Q2';

# Run
my \$parentList = PARENTLISTNAME();
my \$bestScore = 999;
for (my \$i = 1; \$i <= LISTLENGTH(\$parentList); \$i++) {
my \$score = GETVALUE(\$frequencyQuestion . '.' . \$i);
if (\$score) {
if (\$score < \$bestScore) {
REMOVE(\$parentList);
\$bestScore = \$score;
}
if (\$score == \$bestScore) {