5:44 pm - Thursday April 24, 2014

Java Example Program to Print the numbers in Ascending Numbers

//Java Example Program to Print the numbers in Ascending Numbers
/**
@author:candidjava.com
@description:Program to Print the numbers in Ascending Numbers
*/
public class Ascending
{
public static void main(String args[])
{
int n=10;// take input as 10 to print Ascending order
System.out.println("Ascending order upto 10");
for(int i=0; i<=n; i++)// condition for print Ascending order
{
System.out.println(i);
}
}
}

Output:
Ascending order upto 10
0
1
2
3
4
5
6
7
8
9

Filed in: Z-A All Java Codes

Comments are closed.

Social Widgets powered by AB-WebLog.com.