This Java program defines a MyName class with private name and age string and integer fields. The insert method assigns passed name and age parameters to the class fields. The show method prints the name and age fields to output. The main method creates a MyName object, calls the insert method to set the fields, and then calls show to print them.
This Java program defines a MyName class with private name and age string and integer fields. The insert method assigns passed name and age parameters to the class fields. The show method prints the name and age fields to output. The main method creates a MyName object, calls the insert method to set the fields, and then calls show to print them.
This Java program defines a MyName class with private name and age string and integer fields. The insert method assigns passed name and age parameters to the class fields. The show method prints the name and age fields to output. The main method creates a MyName object, calls the insert method to set the fields, and then calls show to print them.
This Java program defines a MyName class with private name and age string and integer fields. The insert method assigns passed name and age parameters to the class fields. The show method prints the name and age fields to output. The main method creates a MyName object, calls the insert method to set the fields, and then calls show to print them.