type Unshift<T extends unknown[], U> = [U, ...T]
Solution by reonce #36051
type Unshift<T extends any[], U> = [U, ...T]
Solution by karazyabko #36033
type Unshift<T extends unknown[], U> = [U, ...T];
Solution by codingaring #35943
// ไฝ ็็ญๆก
type Unshift<T extends readonly unknown[], U extends unknown> = [U, ...T]
Solution by song4613107 #35796
type Unshift<T extends unknown[], U> = [U, ...T]
Solution by ydkim120 #35733
type Unshift<T extends Array<unknown> | ReadonlyArray<unknown>, U> = [U, ...T]
Solution by gangnamssal #35494
type Unshift<T extends unknown [], U> = [U, ...T]
Solution by RanungPark #35444
// your answers
type Unshift<T extends unknown[], U> = [U, ...T];
const myShiftedData: Unshift<[1, 2], 0> = [0, 1, 2];
Solution by Sathiyapramod #35415
type Unshift<T extends unknown[], U> = [U, ...T]
Solution by gyeounjeong #35362
type Unshift<T, U> = T extends any[] ? [U, ...T]: [];
Solution by dailyco #35207
type Unshift<T extends any[], U> = [U, ...T];
Solution by IsaacYouKorea #35206
type Unshift<T extends unknown[], P> = [P, ...T]
Solution by ClarityOfMind #35003
type Unshift<T extends any[], U> = [U, ...T];
Solution by raeyoung-kim #34946
type Unshift<T extends unknown[], U> = T extends never[] ? [U] : [U, ...T]
Solution by 56aiden90 #34887
type Unshift<T extends unknown[], U> = [U, ...T]
Solution by eunsukimme #34817
type Unshift<T extends unknown[], U> = [U, ...T]
Solution by Yuriy113 #34736
// your answers
type Unshift<T extends unknown[], U> = [U, ...T]
Solution by zeyuanHong0 #34726
type Unshift<T extends any[], U> = T["length"] extends 0 ? [U] : [U, ...T];
Solution by lephuthuc2001 #34708
type Unshift<T, U> = T extends any[] ? [U, ...T] : T
Solution by nathan2slime #34664
type Unshift<T extends unknown[], U> = [U, ...T]
// your answers
Solution by Rustamaha #34555
type Unshift<T extends unknown[], U> = [U,...T]
Solution by devshinthant #34550
type Unshift<T extends unknown[], U> = [U, ...T]
Solution by binhdv155127 #34474
// ์ฌ๊ธฐ ํ์ด๋ฅผ ์
๋ ฅํ์ธ์
type Unshift<T extends readonly unknown[], U> = [U, ...T];
Solution by LeeKangHyun #34465
We should add U at array T's first place. So, declare a new array(type) and add U. And, spread T's elements.
// your answers
type Unshift<T extends any[], U> = [U, ...T]
Solution by dev-jaemin #34459
type Unshift<T extends readonly any[], U> = [U, ...T];
Solution by ktim816 #34429
type Unshift<T extends any[], U> = [U, ...T]
Solution by bkdragon0228 #34426
// your answers
type Unshift<T extends any[], U> = [U, ...T]
Solution by gobielJonathan #34400
type Unshift<T extends any[], U> = [U, ...T];
Solution by wxh-cyber #34370
type Unshift<T extends unknown[], U> = [U, ...T]
Solution by souzaramon #34318