<?php
0 => '',
1 => '5 Estacao',
2 => '3 Estacao',
3 => '4 Estacao',
4 => '1 Estacao',
5 => '2 Estacao',
),
0 => '',
1 => '172.168.0.15',
2 => '172.168.0.13',
3 => '172.168.0.14',
4 => '172.168.0.11',
5 => '172.168.0.12',
)
);
function order ($arr)
{
$arr = array_map(null, $arr["sites"], $arr["IPs"]);
usort($arr, function ($a, $b) { });
return [
"sites" => array_column($arr, 0),
"IPs" => array_column($arr, 1)
];
}
PD9waHAKCiRkYXRhID0gQXJyYXkoCiAgICAnc2l0ZXMnID0+IEFycmF5KAogICAgICAgIDAgPT4gJycsCiAgICAgICAgMSA9PiAnNSBFc3RhY2FvJywKICAgICAgICAyID0+ICczIEVzdGFjYW8nLAogICAgICAgIDMgPT4gJzQgRXN0YWNhbycsCiAgICAgICAgNCA9PiAnMSBFc3RhY2FvJywKICAgICAgICA1ID0+ICcyIEVzdGFjYW8nLAogICAgKSwKICAgICdJUHMnID0+IEFycmF5KAogICAgICAgIDAgPT4gJycsCiAgICAgICAgMSA9PiAnMTcyLjE2OC4wLjE1JywKICAgICAgICAyID0+ICcxNzIuMTY4LjAuMTMnLAogICAgICAgIDMgPT4gJzE3Mi4xNjguMC4xNCcsCiAgICAgICAgNCA9PiAnMTcyLjE2OC4wLjExJywKICAgICAgICA1ID0+ICcxNzIuMTY4LjAuMTInLAogICAgKQopOwoKZnVuY3Rpb24gb3JkZXIgKCRhcnIpCnsKICAgICRhcnIgPSBhcnJheV9tYXAobnVsbCwgJGFyclsic2l0ZXMiXSwgJGFyclsiSVBzIl0pOwogICAgCiAgICB1c29ydCgkYXJyLCBmdW5jdGlvbiAoJGEsICRiKSB7CiAgICAgICAgcmV0dXJuIHN0cmNtcCgkYVswXSwgJGJbMF0pOwogICAgfSk7CiAgICAKICAgIHJldHVybiBbCiAgICAgICAgInNpdGVzIiA9PiBhcnJheV9jb2x1bW4oJGFyciwgMCksCiAgICAgICAgIklQcyIgICA9PiBhcnJheV9jb2x1bW4oJGFyciwgMSkKICAgIF07Cn0KCnByaW50X3Iob3JkZXIoJGRhdGEpKTs=