DeepFrontend
Learning Paths
Practice
System Design & DS
Design Studio
Data Structures Curriculum
Real-World Case Studies
Careers
Job Board
Resume Builder
Blog
Sign in
Search
⌘K
Go Pro
Loading compiler resources...
TypeScript Quiz Practice
Active Recall Drill Session
← Exit Session
Question 1 of 1
medium
TypeScript
What does `K extends keyof T` accomplish in `function pluck<T, K extends keyof T>(obj: T, key: K): T[K]`?
A
Nothing meaningful
B
It constrains K to only the actual property names of T, making an invalid key a compile error rather than a silent runtime undefined
C
It makes obj readonly
D
It requires T to be an array
Check Answer