recently in learning TS, refer to this tutorial . For the example given in, use the interface to describe the array
interface NumberArray {
[index: number]: number;
}
let fibonacci: NumberArray = [1, 1, 2, 3, 5];
so, if the code says so
interface NumberArray {
[index: string]: number;
}
so how can I write an array that matches the interface