You are given two strings, s and sub, along with a mappings where mappings[i] sub can be replaced with $ ext{new}_i$. Each character in sub may be replaced at most once, and characters in s cannot be replaced.
Return true if it is possible to make sub a substring of s after replacing zero or more characters in sub using the given mappings. Otherwise, return false.
Note: A substring is a contiguous non empty sequence of characters within a string.
Constraints:
sub.length s.length
mappings.length
mappings[i].length
$ ext{old}_i \neq ext{new}_i$
s and sub consist of uppercase and lowercase English letters and digits.
$ ext{old}_i$ and $ ext{new}_i$ are either uppercase or lowercase English letters or digits.
You are given two strings, s and sub, along with a mappings where mappings[i] sub can be replaced with $ ext{new}_i$. Each character in sub may be replaced at most once, and characters in s cannot be replaced.
Return true if it is possible to make sub a substring of s after replacing zero or more characters in sub using the given mappings. Otherwise, return false.
Note: A substring is a contiguous non empty sequence of characters within a string.
Constraints:
sub.length s.length
mappings.length
mappings[i].length
$ ext{old}_i \neq ext{new}_i$
s and sub consist of uppercase and lowercase English letters and digits.
$ ext{old}_i$ and $ ext{new}_i$ are either uppercase or lowercase English letters or digits.