Question: Exercise 1. Given the following class, called Number Holder, write some code that creates an instance of the class, initializes its two member variables, and

Exercise 1. Given the following class, called Number Holder, write some code that creates an instance of the class, initializes its two member variables, and then displays the value of each member variable. public class Number Holder { public int anlnt; public float a Float; } Exercise 2. A better Number Holder class would have private member variables. If we wanted to make a new class Number Holderlmproved now with privacy!, how would you change the given Number Holder class above and the code you wrote to access those variables? Write your new and improved classes
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
