<div dir="ltr">Hi,<div><br></div><div>Hi @Marc Worrel, I've try using memoize version from <a href="https://rosettacode.org/wiki/Longest_common_subsequence#Erlang">https://rosettacode.org/wiki/Longest_common_subsequence#Erlang</a> <br>and the result also very very slow. </div><div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Pada tanggal Sen, 30 Mar 2020 pukul 21.04 Marc Worrell <<a href="mailto:marc@worrell.nl">marc@worrell.nl</a>> menulis:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div style="overflow-wrap: break-word;"><br><div><blockquote type="cite"><div>On 30 Mar 2020, at 15:45, I Gusti Ngurah Oka Prinarjaya <<a href="mailto:okaprinarjaya@gmail.com" target="_blank">okaprinarjaya@gmail.com</a>> wrote:</div><br><div><div dir="ltr">Hi All,<div><br></div><div>Thank your very much for the answers,<br><div><br></div><div><a class="gmail_plusreply" id="gmail-m_-2712118671787289722plusReplyChip-0" href="mailto:v@micic.co.za" target="_blank">@Valentin Micic</a> , Your lcs function skipping the "World" word. I need "o" and "World" also count. </div><div><br></div><div>@Marc Worrel, Your function also similar with Valentine Micic's function.<br><br>@Richard O'Keefe , I suppose substring or subsequence is same thing, but i think i am wrong, the point is, i need the function to also count </div><div>"o" from <<"Hellaao World">>, and "World" from <<"Hello World">><br>from example: lcs(<<"Hello World">>, <<"Hellaao World">>)</div></div></div></div></blockquote><div><br></div><div>Ah, you needed really a substring function.</div><div>Then best is, indeed, use the C code or add memoization to the Erlang version.</div><div><br></div><div>- Marc</div></div><br></div></blockquote></div>