Write the PHP expression that returns a new array with every number in $numbers squared.
Scenario
You need a transformed copy of $numbers where each value is squared, without mutating the original.
Ready to try it?
Create a free account and try "Write an array_map Expression to Square Values" free for 7 days, no card required. Earn 90 XP and track your internship progress.