Home » Java Basics » arrays

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

In this example we will show how to declare and populate a string array as well as how to iterate through all its elements. 1. Example of 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[]) { // declare a string array with initial size ...

Read More »

Want to take your Java skills to the next level?

Grab our programming books for FREE!

Here are some of the eBooks you will get:

  • Spring Interview QnA
  • Multithreading & Concurrency QnA
  • JPA Minibook
  • JVM Troubleshooting Guide
  • Advanced Java
  • Java Interview QnA
  • Java Design Patterns