#include #include #include #include /** * @brief Computes the edit distance (Levenshtein distance) between two strings. * * The edit distance is defined as the minimum number of single-character edits * (insertions, deletions, or substitutions) required to transform one string into the other. * * This implementation uses dynamic programming to compute the distance efficiently. * * @param s1 The first string. * @param s2 The second string. * @return The edit distance between the two strings. */ int edit_distance(const std::string& s1, const std::string& s2);