单项选择题

A.Youneedtoensurethattheundofunctionalityundoesthemostrecentdatamodificationsfirst.Youalsoneedtoensurethattheundobufferpermitsthestorageofstringsonly.Whichcodesegmentshouldyouuse?()
A.Stack<string>
B.StackundoBuffer=newStack();
C.Queue<string>undoBuffer=newQueue<string>();
D.QueueundoBuffer=newQueue();