Computer Science, asked by dinesh9465, 5 months ago

write a java program to print your name five times​

Answers

Answered by iamvanshika53
4

Answer:

Example 1: Display a Text Five Times. // Program to print a text 5 times class Main { public static void main(String[] args) { int n = 5; // for loop for (int i = 1; i <= n; ++i) { System.out.println("Java is fun"); } } } ...

Example 2: Display numbers from 1 to 5. ...

Example 3: Display Sum of n Natural Numbers.

Answered by khushbukumari401401
4

Answer:

Example 1: Display a Text Five Times. // Program to print a text 5 times class Main { public static void main(String[] args) { int n = 5; // for loop for (int i = 1; i <= n; ++i) { System.out.println("Java is fun"); } } } ...

Example 2: Display numbers from 1 to 5. ...

Example 3: Display Sum of n Natural Number

Similar questions