código

Post on 21-Nov-2015

6 Views

Category:

Documents

3 Downloads

Preview:

Click to see full reader

DESCRIPTION

Código

TRANSCRIPT

Cdigo: Inicializar una matriz (Visual Basic)Visual Studio .NET 2003Este tema an no ha recibido ninguna valoracin-Valorar este temaEn este ejemplo se inicializa una matriz unidimensional, una matriz bidimensional y una matriz escalonada.EjemploDim OneDimArray() As Char = {"X"c, "Y"c, "Z"c}Dim TwoDimArray(,) As Double = {{5.8, 6.6}, {7.4, 8.2}}Dim JaggedArray()() As Integer = {New Integer() {1, 2}, New Integer() {3, 4}}Compilar el cdigoEste ejemplo necesita: Una referencia al espacio de nombresSystem.Vea tambin

Sub studentScores(ByVal name As String, ByVal ParamArray scores() As String) Debug.WriteLine("Scores for " & name & ":" & vbCrLf) ' Use UBound to determine largest subscript of the array. For i As Integer = 0 To UBound(scores, 1) Debug.WriteLine("Score " & i & ": " & scores(i)) Next iEnd Sub

top related