simple code made using dict and beat 90%
\n\n# Code\n\nclass Solution:\n    def canFormArray(self, arr: List[int], pieces: List[List[int]]) -> bool:\n        \n        ## create a dictionary\n        #
\n\n# Code\n```\nclass Solution:\n    def canFormArray(self, arr: List[int], pieces: List[List[int]]) -> bool:\n        \n        ## create a dictionary\n        # key: head number of piece\n        # value: all number of single piece\n        mapping = { piece[0]: piece for piece in pieces }\n        \n        result = []\n        \n        # try to make array from pieces\n        for number in arr:\n            \n            result += mapping.get( number, [] )\n        \n        # check they are the same or not\n        return result == arr\n```
['Python3']