Fintastic interview question

Tech quest 2: Typescript. Write a function returning certain property per type