Don't forget to handle the case when the array is empty:
xxxxxxxxxx
if (!arrOfLists || arrOfLists.length === 0) {
return [];
}
OUTPUT
Results will appear here.
Don't forget to handle the case when the array is empty:
xxxxxxxxxx
if (!arrOfLists || arrOfLists.length === 0) {
return [];
}