Assignment #1


For this assignment you will be writing the first pieces of code for the larger project. At this point your main objective is to create some classes that you will be able to use through out the rest of the project. The classes that you are going to design are one that represents the four character substrings (SubStr4), and one that is a helper class to generate, store, and load those substrings (SubStrHandler). You will also have to use these classes in two small programs the show that they work and have decent functionality.

One of the most significant components of this assignment is working on the design of those classes. The first one could seem like a very insignificant class that only needs to store four characters. However, this class will form the foundation of the semester project. To get a good design you must also have a good analysis of the problem. This is going to be a bit challenging given how little information you have about the project at this point. Still, you should be able to think of certain functionality that you would want in this class.

The second class is a bit more straightforward in the analysis and design, but is also significantly larger. It is a class that will help to keep the many substrings in order. You will be extending this class over time, but for now you should give it the ability to generate all possible substrings of 4 characters (case in not important), save those off, and load them back in. Obviously the saving and loading are a bit absurd if all you are saving and loading are the substrings themselves. In the application you will want to be able to store additional information in a record with each one of those substrings. At this point in time it isn't clear what that extra data is, but for the file to be useful in the future, it will need to leave room for that data. We will actually talk a bit about direct access binary files in order to get it so that we can do this. You won't have to include the details of this in your design.


Submitting Assignments

To submit your assignment to me I want you to e-mail a tarball that includes your source code and if necessary a makefile. If you have questions about how to do this you can first look at the end of this PDF file. If you still have question, feel free to come ask me.