This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package interitanceLab; | |
public class Chiropractor implements DoctorsOffice{ | |
private int patientsWithBackProblems; | |
private double costsPerCustomers; | |
private int numDoctors; | |
private int doctorSalary; | |
public Chiropractor(int patients, double costs, int doctors, int salary) { | |
patientsWithBackProblems = patients; | |
costsPerCustomers = costs; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package inheritance; | |
public class Commission extends Hourly{ | |
public double sales; | |
public double commission; | |
public double allSales; | |
public Commission (String eName, String eAddress, String ePhone, | |
String socSecNumber, double rate, double commissionRate) { | |
super (eName, eAddress, ePhone, socSecNumber, rate); | |
commission = commissionRate; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package mammal; | |
public class Kangaroo { | |
private double pouchVolume; | |
private double highJump; | |
private double tailLength; | |
public double getpouchVolume() { | |
return pouchVolume; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package BusStationPackage; | |
public class BusStation { | |
private String Address; | |
private Bus bus1; | |
private Bus bus2; | |
//non-parameterized constructor | |
public BusStation() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
------------------------------------------------------------------------------------------------------------------- | |
Pset 6 | |
1. What is an infinite loop? | |
An infinate loop is a loop that does not end and has no quit condititon | |
2. How do you prevent an infinite loop? | |
By having a condiditon in which the loop will end/quit. | |
2. Create a while loop which: | |
1. Checks to make sure that the user entered a positive number |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
If public will link work? |