, Visual C#


- 5


' 2- ,

' :

ii = ii + 2

myArrayVB_2(ii, 0) = x2

myArrayVB_2(ii, 1) = y2

myArrayVB_2(ii + 1, 0) = x0

myArrayVB_2(ii + 1, 1) = y0

N_1_myArrayVB_2 = ii + 1 ' .

Exit Do

End If

End If

Loop ' Do - Loop.

' N_first_line N_last_line

' myArrayVB:

Dim N_first_line, N_last_line As Integer

N_first_line = 1

N_last_line = N_1_myArrayVB

' N_first_line

' N_last_line

'myArrayVB(0, 0) myArrayVB(0, 1):

myArrayVB(0, 0) = N_first_line

myArrayVB(0, 1) = N_last_line

 

' myArrayVB(2000, 1):

Dim k As Integer

i = -1

For k = N_first_line To N_last_line

i = i + 2

x1 = myArrayVB(i, 0)

y1 = myArrayVB(i, 1)

x2 = myArrayVB(i + 1, 0)

y2 = myArrayVB(i + 1, 1)

g.DrawLine(myPen, x1, y1, x2, y2)

Next

' N_first_line_2 N_last_line_2

' myArrayVB_2 :

Dim N_first_line_2, N_last_line_2 As Integer

N_first_line_2 = 1

N_last_line_2 = N_1_myArrayVB_2

' N_first_line_2

' N_last_line_2

'myArrayVB_2(0, 0) myArrayVB_2(0, 1):

myArrayVB_2(0, 0) = N_first_line_2

myArrayVB_2(0, 1) = N_last_line_2

' - myArrayVB_2(20000, 1) .

' sw StreamWriter

' D:\MyDocs\MyTest_LevelCurves.txt.

' "":

Dim sw As StreamWriter = _

New StreamWriter("D:\MyDocs\MyTest_LevelCurves.txt")

' myArrayVB_2(i, j) -

' WriteLine:

For i = 0 To N_x_2

For j = 0 To N_y_2

sw.WriteLine(myArrayVB_2(i, j))

Next

Next

sw.Close()

End Sub

. Visual C#, Visual C++ ( ) , , .