-
Notifications
You must be signed in to change notification settings - Fork 0
/
2.ts
executable file
·10 lines (8 loc) · 1.07 KB
/
2.ts
1
2
3
4
5
6
7
8
9
10
// TS playground link: https://tsplay.dev/advent-of-typescript-2023-2
// Christmas Cookie Inventory
// Phew! Yesterday's tactic worked. Santa got down-and-dirty with the elves on the factory floor and they seem to have stopped planning their strike.
// With one small exception.. Unfortunately, two pesky elves (Jingle and Jangle) have realized that the 300 year stock options vesting cliff that Santa put into the elves' contract isn't quite typical. Jingle and Jangle already joined forces with Hermey (who has nothing to lose because he'd rather be a dentist than make toys) and they're beginning to cause a fuss.
// Santa noticed that a lot of this discussion is happening during cookie inventory. Help Santa speed up the process so these conversations are cut short.
// Take a look at the cookieInventory variable in the tests. Your goal is to update CookieSurveyInput so that it will return a union of all of the names of the various different cookies.
// Good luck! As Santa always says: "your hard work will pay off eventually, just be patient".
type CookieSurveyInput<T> = keyof T;