Challenge 3 — Solution Task: Create a global variable $counter = 0. Write a function that creates its own local variable also called $counter, sets it to 100, and echoes it. After calling the function, echo the original global $counter to demonstrate it was never affected — add a comment explaining why. "; } setLocalCounter(); // The global $counter is untouched, because functions have their own // local scope - the $counter inside setLocalCounter() never referred // to the outer one at all, despite sharing the exact same name. echo "Global counter after calling the function: $counter"; ?> Output: Inside the function: 100 Global counter after calling the function: 0 Notes: - Both variables share the name $counter, but PHP treats them as two entirely separate variables because one lives in the global scope and the other lives inside setLocalCounter()'s own local scope. - Setting the local $counter to 100 has zero effect on the global one - this is exactly the "two boxes" diagram from the chapter, just with a counter instead of $x. - Without a global $counter; declaration inside the function (which this solution deliberately doesn't use), there is no way for the function's own assignment to reach outside its own scope.