IntSequence
class should have the following public methods
implemented:Homework Submission
By now, your
public boolean isEmpty()
public int size()
public int elementAt(int pos)
public void add(int toBeAdded)
public String toString()
public int remove(int pos)
public void insert(int toInsert, int insertPos)
public boolean contains(int k)
Submit
IntSequence.java
and IntSequenceTest.java
for homework as hw5
.
Make sure to keep your IntSequence
files as we'll be re-visiting them in a
later lab.Homework Assignments
Read the following:
- HFJ: Chapter 6, p. 302-314
- HFJ: Appendix B 2-3, 5-7, 9
FAQ
Q: Sometimes we call
System.exit(1)
. How can we test this in JUnit?A: You won't be able to test this in JUnit. In the future, we will cover
exceptions, which you will allow you to test for these occurrences.