Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

in eclipse 97% C50, Thu 4:16 PM MR. ROB Q. E Preview File Edit View Go Tools Win

ID: 3789954 • Letter: I

Question

in eclipse

97% C50, Thu 4:16 PM MR. ROB Q. E Preview File Edit View Go Tools Window Help Lab 3 oppIntro.pdf (page 2 of 2 v a Search Lab 3. OPPIntro.pdf Part 3 (9 points) Implement a class Student. (1 point) For the purpose of this exercise, a student has a name and a total quiz score. Include getters and smart setters, like we did in class. (2 points) Supply an appropriate (all variables) constructor (1 point) Implement methods (4 points) 1. getName 0 2. addQuiz(int score) 3. get Total core 4. getAverageScore0. To compute the latter, you also need to store the number of quizzes that the student took. (1 point) Submission Turn in a .zip of your three java files to Canvass by your appropriate due date. Ensure

Explanation / Answer

2)

public class VotingMachine {

    private int votesDemocrats;

    private int votesRepublican;

    public void clear() {

        this.votesDemocrats = 0;

        this.votesRepublican = 0;

    }

    public void voteDemocrats() {

        this.votesDemocrats += 1;

    }

    public void voteRepublicans() {

        this.votesRepublican += 1;

    }

    public void showTalliesOfBothParties() {

        System.out.println("Democrats:" + this.votesDemocrats);

        System.out.println("Republicans: " + this.votesRepublican);

    }

}

3) class Address {