Since 6 people visited two stores each, 12 visitors (6+6) can be deducted from the total 20 visitors.
We now have 8 visitors to be filled in by the remaining 4 people whilst trying to maximize the visits a person could have made. (Note that we cannot consider the 6 people now, as they have visited exactly 2 stores)
The remaining four people (10-6) will be distributed such that the three people visit one store each i.e 1+1+1 and the fourth person visits 5 stores thereby maximizing the number of visits he has.
This can be understood easily by using slots as shown below:
6 slots for six stores: _ _ _ _ _ _
6 people visit exactly 2 stores: 6 6 _ _ _ _
This means, we have considered 12 of 20 visitors. Remaining - 8 visitors
3 people visit exactly 1 of the remaining 3 stores: 6 6 1 1 1 _
Thus we now have considered 15 visitors (6+6+1+1+1)
The 4th person now visits 5 stores: 6 7 2 2 2 1
So the answer is 5