@combined = sort {$a->[0] <=> $b->[0]} (@listone,@listtwo); foreach (@combined) { #check for overlapping times and make sure the smallest V time is listed during the overlap piece #XXXXXXX #break the timespans apart if it covers the crossing of a new day #XXXXXXX }