Source Code:
(back to article)
<?php $original_array = [1, 2, 3, 4, 5]; $new_array = []; foreach ($original_array as $value) { $new_array[] = $value; } print_r($new_array); ?>
Result:
Report an issue