You can specify the type of elements inside an array. For example, number[] is an array that contains only numbers.
typescript
let numbers: number[] = [1, 2, 3, 4, 5];
// numbers.push("hello"); // Error: Argument of type 'string' is not assignable to parameter of type 'number'.
let strings: Array<string> = ["a", "b", "c"];
console.log(numbers[2]);You should see
3