Home / PHP Tips Generated By ChatGPT / Generating a Range of Numbers in PHP Create an array containing a range of elements with range(). Source Code $numbers = range(1, 10); print_r($numbers);