“array cetak” Kode Jawaban

java cara mencetak array

import java.util.Arrays;

class Scratch{
    public static void main(String[] args){
        int[] arr = new int[3];
        System.out.println( Arrays.toString( arr ));
      	//prints [0, 0, 0]
    }
}
Nitbit25

cara mencetak array

System.out.println(Arrays.toString(array));
Obedient Ocelot

Java Cara Mencetak String []

String[] array = new String[] {"John", "Mary", "Bob"};
System.out.println(Arrays.toString(array)); // [John, Mary, Bob]
Pable Sorren

array cetak

String[] array = new String[] {"John", "Mary", "Bob"};
System.out.println(Arrays.toString(array));
Outstanding Ocelot

cara mencetak array js

var array = [1,2,3]

for(var i = 0; i < array.length ; i++){
    console.log(array[i])
}
Powerful Peccary

array cetak

// Array of primitives:
int[] intArray = new int[] {1, 2, 3, 4, 5};
//output: [1, 2, 3, 4, 5]

// Array of object references:
String[] strArray = new String[] {"John", "Mary", "Bob"};
//output: [John, Mary, Bob]
Stupid Skimmer

Jawaban yang mirip dengan “array cetak”

Pertanyaan yang mirip dengan “array cetak”

Lebih banyak jawaban terkait untuk “array cetak” di Java

Jelajahi jawaban kode populer menurut bahasa

Jelajahi bahasa kode lainnya