2 using System
.Collections
;
3 using System
.Collections
.Generic
;
5 public struct S
: IEnumerable
<int>
11 public IEnumerator
<int> GetEnumerator ()
13 return new Enumerator
<int> ();
16 IEnumerator IEnumerable
.GetEnumerator ()
18 throw new ApplicationException ();
24 public IEnumerator
<int> GetEnumerator ()
26 return new Enumerator
<int> ();
30 public struct Enumerator
<T
> : IEnumerator
<T
>
34 throw new NotImplementedException ();
38 object IEnumerator
.Current
{
40 throw new NotImplementedException ();
44 public bool MoveNext ()
51 throw new NotImplementedException ();
54 public void Dispose ()
56 MySystem
.DisposeCounter
++;
62 public static int DisposeCounter
;
64 public static int Main ()
67 foreach (var a
in s
) {
70 if (DisposeCounter
!= 1)
74 foreach (var a
in s2
) {
77 if (DisposeCounter
!= 2)