once you have the number of occurances per line you can just use the MODE function, but are all of those values in multipule cells, or in once cell, with comma seperation