public class array
{
public static void main(String[] args)
{
int [] nilai = new int[5];
nilai [0]=20;
nilai [1]=31;
nilai [2]=44;
nilai [3]=12;
nilai [4]=15;
System.out.println(nilai[3]);
System.out.println(nilai[1]);
System.out.println(nilai[3]);
System.out.println(nilai[0]);
System.out.println(nilai[4]);
}}
Categories:
java