Question: 1 . Write a method in the Gradebook class ( from DF# 1 ) that finds the minimum score of all students. 2 . Write

1. Write a method in the Gradebook class (from DF#1) that finds the minimum score of all students.
2. Write a method in the Gradebook class (from DF#1) that finds the maximum score of all students.
3. Write a Java static method that receives a String as its input parameter and returns true if the given string represents an integer from 0 to 100. The method returns false otherwise.
4. Write a Java static method that receives a String as its input parameter and returns true if the given string represents a valid 7-digit Panther ID. The method returns false otherwise.
5. Predict the outcome of the following program:
class A{
int x;
int decreaseCounter(){
return --x;
}
A (int x){
this.x = x;
}
}
public class B extends A{
private int y;
private int increaseCounter(){
return ++y;
}
public B(int x, int y){
super(x);
this.y = y;
}
public static void main(String[] args){
B b = new B(10,20);
b.increaseCounter();
b.decreaseCounter();
System.out.printf("%d,%d", b.x, b.y);
}
}
6. Predict the output of the following program:
class A{
A (){
System.out.println("A");
}
}
class B extends A{
public B(){
System.out.println("B");
}
}
public class C extends B{
public C(){
System.out.println("C");
}
public static void main(String[] args){
C c = new C();
}
}

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!