Monday, January 31, 2022

Print 1 To 100 Using While Loop in Java

 A simple program to print 1 to 100 using a while loop statement using Java programming language.

I am currently accepting programming work, IT projects, school and application development, programming projects, thesis and capstone projects, IT consulting work, computer tutorials, and web development work kindly contact me in the following email address for further details.  If you want to advertise on my website kindly contact me also in my email address also. Thank you.


My email address is the following jakerpomperada@gmail.com, jakerpomperada@aol.com, and jakerpomperada@yahoo.com.

My mobile number here in the Philippines is 09173084360.

Please subscribe to my channel  https://www.youtube.com/channel/UCOs-lpOoIeJoh6gpJthPoGg

Thank you very much for your support.





Program Listing


public class Print_1_to_100 {


public static void main(String[] args) {

// TODO Auto-generated method stub

int i=1;


System.out.println();

System.out.println("\tPrint 1 To 100 Using While Loop in Java");

System.out.println();


//loop to print 1 to 100.

while(i<=100)

{

 

       System.out.print(" " + i + " ");

    

i++;

}


}


}


No comments:

Post a Comment