Home » Java Basics » arrays


Java 2D Array Example

Java give us the opportunity of using arrays with many dimensions. The most common multi-dimensional arrays that are used in java apps, are one-, two- and three-dimensional. In this example we are going to present some ways of creating 2D arrays, which are represented as tables with row and column style.         1. Example of 2d array ...

Read More »

Java String Array Example

Last updated Jan. 14, 2019 In this example we will show how to declare and populate a Java String Array as well as how to iterate through all its elements. 1. Example of Java String Array Create a java class named JavaStringArrayExample.java with the following code: JavaStringArrayExample.java package com.javacodegeeks.javabasics.stringarray; public class JavaStringArrayExample { public static void main(String args[]) { // ...

Read More »