$data = @("server1","server2","server3")
foreach ($server in $data) {
$results = (Test-Connection $server -count 1 | Measure-Object -Property ResponseTime -Average).Average
}
I'm trying to figure out how to take the output of a ForEach and store the results into an array so I may then compare them later. I could not come up with a way to do this yet.