Busniess Name: Sourabh Sharma
Qtr No. 213, New Town Yehlanka
Indore 454775, India
What is the output of the following TypeScript code?
type Point = [number, number?, number];
let point : Point = [10, 20];
console.log(point);
[10,30]
[10,20,30]
Compilation error: Type '[number, number]' is not assignable to type 'Point'. Source provides no match for the required element at position 2 in the target.
Compilation error: Required parameter cannot follow optional parameter
To get all Infosys Certified TypeScript Developer Exam questions Join Telegram Group https://rebrand.ly/lex-telegram-236dee