1--TEST--
2Test array_product() function with empty array
3--FILE--
4<?php
5$input = [];
6
7echo "array_product() version:\n";
8var_dump(array_product($input));
9
10echo "array_reduce() version:\n";
11var_dump(array_reduce($input, fn($carry, $value) => $carry * $value, 1));
12?>
13--EXPECT--
14array_product() version:
15int(1)
16array_reduce() version:
17int(1)
18