Computer Science, asked by alishyadav8cca, 5 months ago

write a Java Program that accept your name through keyboard and display a greeting​

Answers

Answered by bordoloibubul183
2

Answer:

print ("your name")

only on python

Answered by BrainlyProgrammer
4

Question:-

Q)Java Program to accept your name as input through keyboard and display a greeting

This is a very easy Question, here is an approach

➡️Code:-

package Coder;

import java.util.*;

public class Name

{

public static void main (String ar [])

{

Scanner sc=new Scanner (System.in);

System.out.println("Enter your name");

String name=sc.nextLine();

System.out.println("Hello "+name+"! Welcome to the world of Java");

}

}

Similar questions