Erlang binary longest common substring

Richard O'Keefe raoknz@REDACTED
Mon Mar 30 14:09:56 CEST 2020


You've mentioned three different things:
longest common prefix,
longest common substring,
longest common subsequence.
What do you actually want and why do you want it?
Also, do these binaries represent text?
In that case there's another distinction:
- code points?
- base character + combining characters?
- grapheme cluster?
What I'm getting at is that you *might* want
(O, combining overline) and (O, combining hook above)
to have (O) as a common whatever, but on the other
hand you might *not*.

On Mon, 30 Mar 2020 at 23:18, I Gusti Ngurah Oka Prinarjaya
<okaprinarjaya@REDACTED> wrote:
>
> Hi,
>
> I need longest common substring erlang implementation. Please help me
>
> I've tried https://rosettacode.org/wiki/Longest_common_subsequence#Erlang but very very slow T_T
>
> and i've tried binary:longest_common_prefix([<<"i love you 2020-03-28">>,<<"i love you 2020-03-01">>]) not effective / not valid
>
> Thank you
>


More information about the erlang-questions mailing list