File tree Expand file tree Collapse file tree 1 file changed +20
-0
lines changed
src/main/java/com/example Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Original file line number Diff line number Diff line change @@ -10,6 +10,26 @@ public static void main(String[] args) {
10
10
x = 20 ;
11
11
System .out .println (x );
12
12
13
+ double vetorDouble1 [] = {1 ,2 ,3 ,4 };
14
+ double vetorDouble2 [] = vetorDouble1 ;
15
+
16
+ int vetor3 [] = new int [4 ];
17
+ vetor3 [0 ] = 100 ;
18
+ vetor3 [1 ] = 200 ;
19
+ vetor3 [2 ] = 300 ;
20
+ vetor3 [3 ] = 400 ;
21
+ //vetor3[4] = 500;
22
+ System .out .println (vetorDouble2 );
23
+
24
+
25
+ //System.out.println(Arrays.toString(vetorDouble2));
26
+
27
+ System .out .println ("vetor da posição 0: " + vetorDouble2 [0 ]);
28
+ System .out .println ("vetor da posição 1: " + vetorDouble2 [1 ]);
29
+ System .out .println ("vetor da posição 2: " + vetorDouble2 [2 ]);
30
+ System .out .println ("vetor da posição 3: " + vetorDouble2 [3 ]);
31
+ System .out .println ();
32
+
13
33
double vetor [] = {10 , 20 , 30 ,40 };
14
34
//System.out.println(Arrays.toString(vetor));
15
35
System .out .println ("Vetor na Posição 0 : " + vetor [0 ]);
You can’t perform that action at this time.
0 commit comments