<?php
function oneStep($paths, $pathDone, $time, $point, $target, $visited){
foreach($paths[$point] as $key=> $value){
continue;
}
$time=$paths[$point][$key];
if($time<$pathDone[$point]['time']){
$pathDone[$point]['time']=$time;
$pathDone[$point]['path'][]=$key;
}
$visited=$point;
}
}
PD9waHAKCmZ1bmN0aW9uIG9uZVN0ZXAoJHBhdGhzLCAkcGF0aERvbmUsICR0aW1lLCAkcG9pbnQsICR0YXJnZXQsICR2aXNpdGVkKXsKCmZvcmVhY2goJHBhdGhzWyRwb2ludF0gYXMgJGtleT0+ICR2YWx1ZSl7CiAgICBpZihpbl9hcnJheSgka2V5LCAkdmlzaXRlZCkpewogICAgICAgIGNvbnRpbnVlOwogICAgfQogICAgJHRpbWU9JHBhdGhzWyRwb2ludF1bJGtleV07CiAgICBpZigkdGltZTwkcGF0aERvbmVbJHBvaW50XVsndGltZSddKXsKJHBhdGhEb25lWyRwb2ludF1bJ3RpbWUnXT0kdGltZTsKJHBhdGhEb25lWyRwb2ludF1bJ3BhdGgnXVtdPSRrZXk7ICAKCn0KJHZpc2l0ZWQ9JHBvaW50Owp9Cn0=