首页 新闻 赞助 找找看

有一道英文题,请英语高手帮忙翻译,很短。谢谢!

0
悬赏园豆:30 [待解决问题]

you are createing an undo buffer that stores data modifications. you need to ensure that the undo functionality undoes the most recent data modifications first.you also need to ensure that the undo buffer permits the storage or strings only .

答案有两个

A Stack<string> undoBuffer = new Stack<string>();

A Queue<string> undoBuffer = new Queue<string>();

大概知道是考察队列和堆栈的知识的。 先进先出和先进后出。

任延伟的主页 任延伟 | 初学一级 | 园豆:69
提问于:2010-09-12 17:49
< >
分享
所有回答(8)
0

A

恋恋风尘 | 园豆:185 (初学一级) | 2010-09-12 19:16
0

考undo嘛,当然是先进后出,典型的栈结构,Stack .

killkill | 园豆:1192 (小虾三级) | 2010-09-12 19:18
0

you are createing an undo buffer that stores data modifications.
你正在创建一个用来保存数据修改的撤消缓冲存储器。
you need to ensure that the undo functionality undoes the most recent data modifications first.
你必须确定撤消操作是将最近修改的数据撤消(是stack)
you also need to ensure that the undo buffer permits the storage or strings only .
你必须确定撤消缓冲存储器只允许保存字符串。

ZhangPeng.Chen | 园豆:250 (菜鸟二级) | 2010-09-12 19:30
0

你需要建立一个可释放的缓冲区存储需要修改的数据,并且这个缓冲区,还要允许相应的方法能获取到最新的要修改的数据以及保证能存储对象和字符串。

storage这里应该是用来表明要存储对象的。

chenleinet | 园豆:270 (菜鸟二级) | 2010-09-12 22:44
0

you are createing an undo buffer that stores data modifications.

你正在创建一个撤消存储数据更正的缓冲。

 you need to ensure that the undo functionality undoes the most recent data modifications first.

首先,你必须保证那个撤消方法是撤消最近的数据更改。

you also need to ensure that the undo buffer permits the storage or strings only .

你也必须保证撤消缓冲只允许存储或字符串。

寒狐 | 园豆:433 (菜鸟二级) | 2010-09-13 15:31
0

上来学习一下.

changbluesky | 园豆:854 (小虾三级) | 2010-09-14 09:07
0

A

Ms'h | 园豆:220 (菜鸟二级) | 2010-09-14 18:04
0

就是要你实现一个撤销的功能,undo,也就是word里面经常点的那两弯弯的小箭头。

 

可以返回到上一个状态,经常用ctrl+z也可以实现。

你需要一个容器来存储每次的状态,容器返回的应该是上一次的状态,明显的是“后进先出”

用栈存储所有的状态,

Virus-BeautyCode | 园豆:1619 (小虾三级) | 2010-09-26 12:57
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册