Computer Science, asked by brejeshooty, 1 year ago

write a program in java to print your name five times

Answers

Answered by tanishqsingh
2
import java.io.*
class Abc
 {
BufferedReader br=new BufferedReader( new InputStreamReader (System.in));
public void work ()throws IOException
{  String x;
System.out.println("Enter Your name");
x=br.readline();
 for (i=1;i<=5;i++)
   System.out.println(x);
}
}

 
Answered by Anonymous
3
/* * First Java program, which says "Hello, world!" */ public class Hello { // Save as "Hello.java" public static void main(String[] args) { System.out.println("Hello, world!"); // print message } }
Similar questions