LeetCode 1813. Sentence Similarity III
Input: sentence1 = "My name is Haley", sentence2 = "My Haley"
Output: true
Explanation: sentence2 can be turned to sentence1 by inserting "name is" between "My" and "Haley".Input: sentence1 = "of", sentence2 = "A lot of words"
Output: false
Explanation: No single sentence can be inserted inside one of the sentences to make it equal to the other.Input: sentence1 = "Eating right now", sentence2 = "Eating"
Output: true
Explanation: sentence2 can be turned to sentence1 by inserting "right now" at the end of the sentence.Input: sentence1 = "Luky", sentence2 = "Lucccky"
Output: falseSolution
PreviousLeetCode 1812. Determine Color of a Chessboard SquareNextLeetCode 1814. Count Nice Pairs in an Array
Last updated