excel队列( 二 )


Sub testQueue()
With qTest
‘入队
.Add “甲”
.Add “乙”
.Add “丙”
.Add “丁”
Debug.Print “出队顺序:”
‘出队
Do While Not .QueueEmpty
Debug.Print .Remove()
Loop
End With
End Sub
运行后的结果如下图6所示 。可以看到,出队的顺序与入队的顺序相同 。

excel队列


【excel队列】图6

猜你喜欢