Examples of words:
- ball
- encyclopedia
- tableau
Examples of random strings:
- qxbogsac
- jgaynj
- rnnfdwpm
Of course it may happen that a random string will actually be a word in some language or look like one. But basically a human being is able to say it something looks 'random' or not, basically just by checking if you are able to pronounce it or not.
I was trying to calculate entropy to distinguish those two but it's far from perfect. Do you have any other ideas, algorithms that works?
There is one important requirement though, I can't use heavy-weight libraries like nltk
or use dictionaries. Basically what I need is some simple and quick heuristic that works in most cases.
Works quite well for me: