updated MIOA with priority queue