枚举类型
摘要:
namespace ConsoleApplication1{ public class Stack : IEnumerable { public int[] items = { 0, 1, 2, 3 }; public IEnumerator GetEnumerator() { for (int i = 0; i < items.Length; i++) yield return items[i]; } } class Program { static void Main(string[] args) { Stack stack=new Stack(); IEnumerator i=st 阅读全文
posted @ 2010-08-05 22:15 java课程设计 阅读(176) 评论(0) 推荐(0) 编辑