• 2022-06-06 问题

    用户类若想支持Foreach语句需要实现的接口是:() A: IEnumerable B: IEnumerator C: ICollection D: ICollectData

    用户类若想支持Foreach语句需要实现的接口是:() A: IEnumerable B: IEnumerator C: ICollection D: ICollectData

  • 2022-06-06 问题

    对于集合元素的遍历,最好是用foreach语句。foreach与 for语句类似,两者都允许遍历集合中的元素,但 A: for语句的可枚举表达式实现了IEnumerable接口 B: for语句比foreach速度要快 C: foreach语句不用索引变量 D: foreach语句没有循环体

    对于集合元素的遍历,最好是用foreach语句。foreach与 for语句类似,两者都允许遍历集合中的元素,但 A: for语句的可枚举表达式实现了IEnumerable接口 B: for语句比foreach速度要快 C: foreach语句不用索引变量 D: foreach语句没有循环体

  • 1