Skip to main content
2 of 3
added 7 characters in body
user
  • 457
  • 2
  • 21
  • 71

Java (JDK), 129 bytes

Saved 10 bytes thanks to @ceilingcat!

s->{int m=0,z=s.length()+1,a[]=new int[z];for(var x:s.split("[^a-zA-Z]+"))a[x.length()]++;for(;z-->0;m=a[z]>a[m]?z:m);return m;}; 

Try it online!

user
  • 457
  • 2
  • 21
  • 71