Hi,

r:=[3,3,3,3,4,4,4,3,3,3,3,3,3,3,3,2,4,3,1];

What's the shortest way to create a frequency table from it?

Ie, tells me elements are 1,2,3,4

the corresponding counts are: 1,1,13 and 4

and then if it can return the number with highest counts: 3

Many thanks!

Casper