write a main method to create an object of the class and all the above members method
Answers
Answered by
69
Answer:
To create an object of MyClass , specify the class name, followed by the object name, and use the keyword new :
Example. Create an object called " myObj " and print the value of x: public class Main { int x = 5; public static void main(String[] args) { Main myObj = new Main(); System. ...
ᎻᎾᏢᎬ ᎨᎿ ᎻᎬᏝᏢᏕ ᎽᎾᏬ
Answered by
3
Explanation:
ANSWER ✍️
To create an object of MyClass , specify the class name, followed by the object name, and use the keyword new :
Example. Create an object called " myObj " and print the value of x: public class Main { int x = 5; public static void main(String[] args) { Main myObj = new Main(); System.
ᎻᎾᏢᎬ ᎨᎿ ᎻᎬᏝᏢᏕ ᎽᎾᏬ!
Similar questions