Can you please take a look at this script and let me know why I am getting the
Undefined variable: step1
error?
<?php
$step1;
function getNums($num1, $num2){
$diff = $num2 - $num1;
$steps =[
round($num1 + $diff/4),
round($num1 + $diff/2),
round($num1 + $diff*.75),
$num2
];
$step1 = $steps[1];
}
getNums(50, 400);
echo $step1;
?>