Core Java| JSP| Servlets| XML| EJB| JEE5| Web Services| J2ME| Glossary| Questions?

 

 

 

 

 

 

 

 

 

 

 

 

 

Search Tutorials:
 

Software Solutions and Services
 

 
  JDO Tutorials
  EAI Articles
  Struts Tutorials
  Java Tutorials
  Java Certification
  Java Applet
Questions
Comments
 
Java Arrays Tutorial 
 

Learn Java Arrays from scratch with ease. The topics listed below will enhance your array programming to a great extent.

 

Java Arrays Tutorial

                         

Learn Java Arrays from scratch with ease. The topics listed below will  enhance your  array programming to a great extent. Every topic improves your logic and makes you more keen to go for next. Every example has been illustrated in a simple and conceptual way. A rich variety of  examples have been included which a user can download.

  1. Introduction to Java Arrays
    In this section you will be introduced to the concept of Arrays in Java Programming language. You will learn how the Array class in java  helps the programmer to organize the same type of data into easily manageable format. 
      
  2. Structure of Java Arrays
    Now lets study the structure of Arrays in java. Array is the most widely used data structure in java. It can contain multiple values of the same type. Moreover, arrays are always of fixed length i.e. the length of an array cannot be increased or decreased.
      
  3. Java Array Declaration
    As we declare a variable in Java, An Array variable is declared the same way. Array variable has a type and a valid Java identifier
      
  4. Java Array Initialization
    After the declaration of an array variable, memory is allocated to it. The "new" operator is used for the allocation of  memory to objects.
      
  5. Java Array Usage
    We have already discussed that to refer an element within an array, we use the [] operator. The [] operator takes an "int" operand and returns the element at that index. We also know that the array indices start with zero, so the first element will be held by the 0 index.
      
  6. Copying Arrays
    After learning all about arrays, there is still one interesting thing left to learn i.e. copying arrays. It means to copy data from one array to another.
      
  7. Two Dimensional Array
    Two-dimensional arrays are defined as " an array of arrays". Since an array type is a first-class Java type, we can have an array of ints, etc.
      
  8. Multi Dimensional Array
    So far we have studied about the one-dimensional and two-dimensional arrays. To store data in more dimensions a multi-dimensional array is used. A multi-dimensional array of dimension n is a collection of items.
       

Sorting Algorithms

  1. Bubble Sorting Algorithm
    In this example we are going to sort integer values of an array using bubble sort.
      
  2. Bi-directional Bubble Sort In Java
    A alternative of bubble sort is bi-directional bubble sort. The  bi-directional bubble sort compares each adjacent pair of elements in an array.
  1. Heap Sort Algorithm In Java
    In this example we are going to sort integer values of an array using heap sort. There are two types of heap. First one is  Max heap and second one is min heap.
       
  2. Insertion Sort Algorithm In Java
    Insertion sorting algorithm is similar to bubble sort. But insertion sort is more  efficient than bubble sort because in insertion sort the elements comparisons are less as compare to bubble sort.
      
  3. Merge Sort Algorithm In Java
    In merge sorting algorithm unsorted values are divided into two equal parts iteratively. Then merge both parts and sort it. Then again merge the next part and sort it.
      
  4. Extra Storage Merge Sort in Java
    In extra storage merge sorting algorithm  the unsorted values divide into two equal parts iteratively and create an array for store data value in extra storage.
       
  5. Odd Even Transposition Sort In Java
    In this example we are going to sort integer values of an array using odd even transposition sort. Odd even transposition sort is a parallel sorting algorithm. Odd Even is based on the Bubble Sort technique.
      
  6. Quick Sort Algorithm In Java
    Quick sort algorithm is developed by C. A. R. Hoare. Quick sort is a comparison sort. The working of  quick sort algorithm is depending on a divide-and-conquer strategy.
      
  7. Selection Sort Algorithm In Java
    In this example we are going to sort the values of an array  using selection sort.
    In selection sorting algorithm, find the minimum value in the array then swap it first position.
      

Java Beginners Tutorial.

                         

» View all related tutorials
Related Tags: java c string arrays com array class strings object io objects type command new int id ai define for example

Leave your comment:

Name:

Email:

URL:

Title:

Comments:


Enter Code:

Audio Version
Reload Image
 

Note: Emails will not be visible or used in any way, and are not required. Please keep comments relevant. Any content deemed inappropriate or offensive may be edited and/or deleted.

No HTML code is allowed. Line breaks will be converted automatically. URLs will be auto-linked. Please use BBCode to format your text.

Add This Tutorial To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 

Current Comments

3 comments so far (
post your own) View All Comments Latest 10 Comments:

hello im roland from sti munoz edsa and i want to have an example of array program with one dimension

Posted by rolando ragual on Monday, 09.29.08 @ 08:45am | #80757

If i create the array of class and assign the value to the class member,debuging error is occur.
Why?

Posted by finger on Sunday, 08.3.08 @ 22:27pm | #70792

Very nice tutorial!! This is really a big help.. Thanks.. Hoping for more tutorials..

Posted by Vanessa Castro on Monday, 10.8.07 @ 12:38pm | #32458

Training Courses
Tell A Friend
Your Friend Name
Website Designing Services
 
Web Designing Packages From $150!
 
Website Designing Company Web Hosting
 
Website Designing Quotation
 
Search Tutorials:

 

 
 

Home | JSP | EJB | JDBC | Java Servlets | WAP  | Free JSP Hosting  | Search Engine | News Archive | Jboss 3.0 tutorial | Free Linux CD's | Forum | Blogs

About Us | Advertising On RoseIndia.net  | Site Map

India News

Indian Software Development Company | iPhone Development Company in India | Flex Development Company in India | Java Training Delhi | Java Training at Noida |

Send your comments, Suggestions or Queries regarding this site at roseindia_net@yahoo.com.

Copyright © 2008. All rights reserved.