Answer:
public class Location {
//Class member (instance) variables
public int row;
public int col;
public double maxValue;
//The constructor
public Location(int row, int col, double maxValue) {
this.row = row;
this.col = col;
this.maxValue = maxValue;
}
}
Step-by-step explanation:
- Above is the solution in Java
- The three instance variables are created with public access modifier, and respective data types as required by the question
- A constructor that initializes the three fields is also created.