Leetcode Easy Question Of Array Methods In Typescript Vs Js