问答题

简答题 能用foreach遍历访问的对象需要实现?

【参考答案】

需要实现IEnumerable接口和GetEnumerator()方法。