Type Challenges Judge
Problems
Progress
Get Optional
Implement the advanced util type GetOptional<T>, which remains all the optional fields
GetOptional<T>
For example
type I = GetOptional<{ foo: number, bar?: string }> // expected to be { bar?: string }