Commit c55e424c authored by Ari Trachtenberg's avatar Ari Trachtenberg
Browse files

Test push

parent cb54b45c
Loading
Loading
Loading
Loading
+3 −4
Original line number Diff line number Diff line
@@ -7,7 +7,6 @@ public class MyDistinctCounter extends DistinctCounter {
   */
  public MyDistinctCounter(int memBits) {
    super(memBits);
    throw new NotYetImplemented();  // replace this with your code!
  }

  /**
@@ -15,15 +14,15 @@ public class MyDistinctCounter extends DistinctCounter {
   */
  @Override
  void saw(String newElement) {
    throw new NotYetImplemented();  // replace this with your code!
    mem.set(Math.abs(newElement.hashCode()%(mem.len)));
  }

  /**
   * @inheritDoc
   */
  @Override
  Integer numDistinct() {  // replace this with your code!
    return 0;
  Integer numDistinct() {
    return mem.bits.cardinality();
  }

  // NESTED CLASSES