This is a Java program that defines a class called Welcome with a method print_msg(). The print_msg() method simply prints a message "Welcome Java Exercise" to the console.
The program also contains the main() method, which creates an instance of the Welcome class and calls its print_msg() method to print the welcome message to the console.
When the program is run, it will print the message "Welcome Java Exercise" to the console.
import java.util.*; class Welcome { public void print_msg() { System.out.println("Welcome Java Exercise"); } public static void main(String s[]) { Welcome obj = new Welcome(); obj.print_msg(); } }
Welcome Java Exercise
Learn All in Tamil © Designed & Developed By Tutor Joes | Privacy Policy | Terms & Conditions