Function longestComSubsequence

  • EN: Computes the longest common subsequence of two strings.

    ZH: 计算两个字符串的最长公共子序列

    Usage:

    const ret = longestComSubsequence('fish', 'finish');
    console.log(ret);

    Output:

    4
    

    Parameters

    • aStr: string

      字符串

    • bStr: string

      字符串

    Returns number

    长度