pub fn prefix(s1: &str, s2: &str) -> usize
Calculate common prefix length for two strings.
A wrapper for Prefix.
Prefix
use textdistance::str::prefix; assert!(prefix("abc", "acbd") == 1); // "a"