Practice question from Advanced Typescript
What will be the type of merged in this intersection? A. { x: number } | { y: string } B. { x?: number, y?: string } C. { x: number, y: string } D. unknown E. never
type A = { x: number };
type B = { y: string };
type Merged = A & B;Answer
C
Explanation
An intersection type combines all properties from both types