Implement a method that executes an array of promise-returning functions sequentially, waiting for each to complete before starting the next.
Method signature:
async function sequence<T>(
promiseFunctions: (() => Promise<T>)[]
): Promise<T[]> {
// Implementation goes here
}
Implement a method that executes an array of promise-returning functions sequentially, waiting for each to complete before starting the next. Method signature: