In structural typing, a type which matches another type, but contains extra properties, is considered a subtype. In TypeScript Example:
const;
The
Code which can be checked at runtime.
Type safe function:
const;
A type parameter (see above) which is not wrapped in something like an array.
Example:
// T here is any element in the array
// T[] is the array itself
const filter = <T>(array: T[], func: (T): boolean): T[] => {}