MCPcopy Create free account
hub / github.com/careercup/ctci / Bus

Class Bus

java/Chapter 8/Question8_4/Bus.java:3–16  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1package Question8_4;
2
3public class Bus extends Vehicle {
4 public Bus() {
5 spotsNeeded = 5;
6 size = VehicleSize.Large;
7 }
8
9 public boolean canFitInSpot(ParkingSpot spot) {
10 return spot.getSize() == VehicleSize.Large;
11 }
12
13 public void print() {
14 System.out.print("B");
15 }
16}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected