Write a Java program to welcome to the world of computer with output
Answers
Explanation:
Program :
Program :class print
Program :class print{
Program :class print{void main()
Program :class print{void main(){
Program :class print{void main(){System.out.println("welcome to the world of computers");
Program :class print{void main(){System.out.println("welcome to the world of computers");}
Program :class print{void main(){System.out.println("welcome to the world of computers");}}
Program :class print{void main(){System.out.println("welcome to the world of computers");}}Note :
Program :class print{void main(){System.out.println("welcome to the world of computers");}}Note :(i) The statement " System.out.println" prints the line .
Program :class print{void main(){System.out.println("welcome to the world of computers");}}Note :(i) The statement " System.out.println" prints the line .(ii) A class begins with a curly bracket and ends with one .
Program :class print{void main(){System.out.println("welcome to the world of computers");}}Note :(i) The statement " System.out.println" prints the line .(ii) A class begins with a curly bracket and ends with one .(iii) The method main() also begins with curly bracket and ends with curly braces too.
Program :class print{void main(){System.out.println("welcome to the world of computers");}}Note :(i) The statement " System.out.println" prints the line .(ii) A class begins with a curly bracket and ends with one .(iii) The method main() also begins with curly bracket and ends with curly braces too.(iv) Don't forget to write the relevant class name . The class name here is "print" .
Answer:
public class
{
public static void main()
{ System.out.println(" welcome to the world of computer")
}
}