MCPcopy
hub / github.com/careercup/ctci / removeLocation

Method removeLocation

java/Chapter 8/Question8_8/Automator.java:45–52  ·  view source on GitHub ↗
(int r, int c)

Source from the content-addressed store, hash-verified

43 }
44
45 public void removeLocation(int r, int c) {
46 for (int i = 0; i < remainingMoves.size(); i++) {
47 Location loc = remainingMoves.get(i);
48 if (loc.isSameAs(r, c)) {
49 remainingMoves.remove(i);
50 }
51 }
52 }
53
54 public Location getLocation(int index) {
55 return remainingMoves.get(index);

Callers

nothing calls this directly

Calls 4

isSameAsMethod · 0.95
sizeMethod · 0.45
getMethod · 0.45
removeMethod · 0.45

Tested by

no test coverage detected