1. Home
  2. Computing & Technology
  3. Java

for

By Paul Leahy, About.com

Definition:

The for keyword is used to define the beginning of a for loop and is always written in lowercase.

Examples:

Using a for loop to print out the numbers from 1 to 10:

for (int i=1; i<=10; i++)
{
  System.out.println(i);
}

Glossary:

# A B C D E F G H I J K L M N O P Q R S T U V W X Y Z

Explore Java
About.com Special Features

Stay connected and entertained with reviews on tips on the latest HDTVs, cellphones and more. More >

Easy ways to connect two computers for networking purposes. More >

  1. Home
  2. Computing & Technology
  3. Java
  4. Java Glossary
  5. F
  6. for - Definition for the Term: for>

©2009 About.com, a part of The New York Times Company.

All rights reserved.