algorithm

leetcode 1662

소소한 프로그래머 2022. 10. 25. 15:48
1662. Check If Two String Arrays are Equivalent 매우 간단한 문제다.
class Solution:
    def arrayStringsAreEqual(self, word1: List[str], word2: List[str]) -> bool:
        
        mergedWord1 = ''.join(word1)
        mergedWord2 = ''.join(word2)
        
        return mergedWord1 == mergedWord2