Write a TypeScript function that accepts an array of numbers and returns the maximum value.
Naresh Beniwal