Descargar la presentación
La descarga está en progreso. Por favor, espere
Publicada porJorge Castellanos Lara Modificado hace 8 años
1
ING.CIP.IVAN PETRLIK AZABACHE
3
ARREGLOS Conjunto de espacios de memoria uno a continuacion del otro.Pertenece a un solo tipo de dato donde cada Espacio de memoria es identificado por un indice.
4
TIPOS DE ARREGLOS ARREGLOS UNIDIMENSIONALES(VECTORES)
5
TIPOS DE ARREGLOS ARREGLOS BIDIMENSIONALES(MATRICES)
6
ARREGLO UNIDIMENSIONAL EN UNA MISMA LINEA: int x[ ] = new int [ 3 ] ; String nomb [ ] = new String [ 4 ] ; EN DOS LINEAS: int x [ ] ; x = new int [ 3 ] ; String nomb[]; nomb=new String [ 4 ] ;
7
DECLARACION E ASIGNACION En Una Misma Linea: int x[ ]= { 3,5,4,6 }; String nomb[]={ “ivan”,”carlo”,”beto”,”wily”}; En mas de una Linea : int x [ ]= new int [ 3 ]; x [ 0 ] = 3 ; x [ 1 ] = 5 ; x [ 2 ] = 4 ; x [ 3 ] = 6 ;
8
ARREGLO BIDIMENSIONAL EN UNA MISMA LINEA: int x[ ] [ ] = new int [ 3 ] [3 ] ; String nomb [ ] [ ] = new String [ 4 ] [4 ] ; EN DOS LINEAS: int x [ ] [ ] ; x = new int [ 3 ] [3 ] ; String nomb[] [ ] ; nomb=new String [ 4 ] [4 ] ;
9
DECLARACION E ASIGNACION En Una Misma Linea: int x[ ] [ ] = { { 3, 5}, {4, 6 } }; String nomb[] [ ] ={ {“ivan”,”carlo”}, {”beto”,”wily” }}; En mas de una Linea : int x [ ] [ ] = new int [ 2] [ 2] ; x [ 0 ] [0 ] = 3 ; x [ 1 ] [ 1] = 5 ;
Presentaciones similares
© 2024 SlidePlayer.es Inc.
All rights reserved.