Indexable type for objects in TypeScript

Now let's make an indexable type for the object. To do this, we'll create the IObject interface. We'll specify that the object's key will be a string and its value will be a number:

typescriptinterface IObject {
  [index: string]: number;
}

Let's give our variable a value in the form of an object with string keys and numeric values:

typescriptlet obj: IObject = {'a': 1, 'b': 2, 'c': 3};
Задание 1

Create an interface that describes an object with keys as numbers and values ​​as strings.