Page 3 - java programs
P. 3

public class JavaProgram

            {


                public static void main(String args[])


                {



                    int n=1, i;


                    for(i=0; i<10; i++)


                    {



                        System.out.println(n);


                        n++;


                    }


                }



            }



            When the above Java program is compile and executed,
            it will produce the following output:
   1   2   3   4   5   6