Friday, 5 September 2014

simple program for print 1 to 10 using for loop, example of integer value, simple example for integer variale

Program of Print the Integer value in 1 to 10

 
 
class Integers {
  public static void main(String[] arguments) {
    int c; //declaring a variable
 
  /* Using for loop to repeat instruction execution */
 
    for (c = 1; c <= 10; c++) {
      System.out.println(c);
    }
  }
}

0 comments:

Post a Comment

 
Copyright © . StackOverflow - Posts · Comments
· Powered by Sanjay Chauhan